1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-12-25 07:58:19 +00:00

Fix #999 outfile for recovered hash not longer working

This commit is contained in:
jsteube 2017-01-27 23:44:49 +01:00
parent 518983d3a0
commit 322862f8dc

View File

@ -1499,6 +1499,8 @@ int user_options_check_files (hashcat_ctx_t *hashcat_ctx)
// outfile - can be NULL // outfile - can be NULL
if (outfile_ctx->filename != NULL) if (outfile_ctx->filename != NULL)
{
if (hc_path_exist (outfile_ctx->filename) == true)
{ {
if (hc_path_write (outfile_ctx->filename) == false) if (hc_path_write (outfile_ctx->filename) == false)
{ {
@ -1506,9 +1508,13 @@ int user_options_check_files (hashcat_ctx_t *hashcat_ctx)
return -1; return -1;
} }
}
}
// check for hashfile vs outfile (should not point to the same physical file) // check for hashfile vs outfile (should not point to the same physical file)
if ((user_options_extra->hc_hash != NULL) && (outfile_ctx->filename != NULL))
{
char *hashfile = user_options_extra->hc_hash; char *hashfile = user_options_extra->hc_hash;
char *outfile = outfile_ctx->filename; char *outfile = outfile_ctx->filename;