Fix file locking (again).

This commit is contained in:
magnum
2016-11-05 11:33:29 +01:00
parent fb8fb6b21d
commit a52b96583f
8 changed files with 57 additions and 1 deletions

View File

@@ -8,6 +8,7 @@
#include "memory.h"
#include "event.h"
#include "debugfile.h"
#include "locking.h"
static void debugfile_format_plain (hashcat_ctx_t *hashcat_ctx, const u8 *plain_ptr, const u32 plain_len)
{
@@ -112,6 +113,13 @@ int debugfile_init (hashcat_ctx_t *hashcat_ctx)
return -1;
}
if (lock_file (debugfile_ctx->fp) == -1)
{
event_log_error (hashcat_ctx, "%s: %s", debugfile_ctx->filename, strerror (errno));
return -1;
}
}
else
{