Fix file locking (again).
This commit is contained in:
@@ -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
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user