VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/ExpandVolume/InitDataArea.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ExpandVolume/InitDataArea.c')
-rw-r--r--src/ExpandVolume/InitDataArea.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/ExpandVolume/InitDataArea.c b/src/ExpandVolume/InitDataArea.c
index a3793e86..c1eb6bd2 100644
--- a/src/ExpandVolume/InitDataArea.c
+++ b/src/ExpandVolume/InitDataArea.c
@@ -58,8 +58,12 @@ Original legal notice of the TrueCrypt source:
#include "Resource.h"
#include "InitDataArea.h"
+#ifndef SRC_POS
+#define SRC_POS (__FUNCTION__ ":" TC_TO_STRING(__LINE__))
+#endif
+
int FormatWriteBufferSize = 1024 * 1024;
static uint32 FormatSectorSize = 0;
void SetFormatSectorSize(uint32 sector_size)
@@ -225,9 +229,9 @@ static void __cdecl FormatWriteThreadProc (void *arg)
while (!WriteThreadExitRequested)
{
if (WaitForSingleObject (WriteBufferFullEvent, INFINITE) == WAIT_FAILED)
{
- handleWin32Error (NULL);
+ handleWin32Error (NULL, SRC_POS);
break;
}
if (WriteThreadExitRequested)
@@ -239,9 +243,9 @@ static void __cdecl FormatWriteThreadProc (void *arg)
WriteRequestResult = ERROR_SUCCESS;
if (!SetEvent (WriteBufferEmptyEvent))
{
- handleWin32Error (NULL);
+ handleWin32Error (NULL, SRC_POS);
break;
}
}