diff options
Diffstat (limited to 'src/htshash.c')
-rw-r--r-- | src/htshash.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/htshash.c b/src/htshash.c index 15af190..7bdf782 100644 --- a/src/htshash.c +++ b/src/htshash.c @@ -34,11 +34,11 @@ Please visit our Website: http://www.httrack.com /* Internal engine bytecode */ #define HTS_INTERNAL_BYTECODE +#include "htsopt.h" #include "htshash.h" /* specific definitions */ #include "htsbase.h" -#include "htsopt.h" #include "htsglobal.h" #include "htsmd5.h" #include "htscore.h" @@ -171,12 +171,20 @@ static int key_former_adrfil_equals(void *arg, const char *a, const char *b) { return key_adrfil_equals_generic(arg, a, b, 1); } -void hash_init(hash_struct * hash, int normalized) { +void hash_init(httrackp *opt, hash_struct * hash, int normalized) { hash->sav = inthash_new(0); hash->adrfil = inthash_new(0); hash->former_adrfil = inthash_new(0); hash->normalized = normalized; + hts_set_hash_handler(hash->sav, opt); + hts_set_hash_handler(hash->adrfil, opt); + hts_set_hash_handler(hash->former_adrfil, opt); + + inthash_set_name(hash->sav, "hash->sav"); + inthash_set_name(hash->adrfil, "hash->adrfil"); + inthash_set_name(hash->former_adrfil, "hash->former_adrfil"); + /* Case-insensitive comparison ; keys are direct char* filenames */ inthash_value_set_key_handler(hash->sav, key_duphandler, |