mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-27 02:18:21 +00:00
Merge pull request #1315 from philsmd/master
fixes #1314: do not use the defines INSTALL_FOLDER/SHARED_FOLDER but the values from folder config
This commit is contained in:
commit
fcc8b4be3f
@ -158,21 +158,18 @@ static int read_restore (hashcat_ctx_t *hashcat_ctx)
|
|||||||
* updated folders
|
* updated folders
|
||||||
*/
|
*/
|
||||||
|
|
||||||
const char *install_folder = NULL;
|
// copy the paths of INSTALL_FOLDER and SHARED_FOLDER from the folder config:
|
||||||
const char *shared_folder = NULL;
|
|
||||||
|
|
||||||
#if defined (INSTALL_FOLDER)
|
char *install_folder = hcstrdup (folder_config->install_dir);
|
||||||
install_folder = INSTALL_FOLDER;
|
char *shared_folder = hcstrdup (folder_config->shared_dir);
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined (SHARED_FOLDER)
|
|
||||||
shared_folder = SHARED_FOLDER;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
folder_config_destroy (hashcat_ctx);
|
folder_config_destroy (hashcat_ctx);
|
||||||
|
|
||||||
const int rc_folder_config_init = folder_config_init (hashcat_ctx, install_folder, shared_folder);
|
const int rc_folder_config_init = folder_config_init (hashcat_ctx, install_folder, shared_folder);
|
||||||
|
|
||||||
|
hcfree (install_folder);
|
||||||
|
hcfree (shared_folder);
|
||||||
|
|
||||||
if (rc_folder_config_init == -1) return -1;
|
if (rc_folder_config_init == -1) return -1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user