diff options
author | Stef Walter <stef@memberwebs.com> | 2004-06-09 16:39:31 +0000 |
---|---|---|
committer | Stef Walter <stef@memberwebs.com> | 2004-06-09 16:39:31 +0000 |
commit | 66d68a58fbbeacfaa51f5210e9d6a549a677014f (patch) | |
tree | c0bcad3aae498452aecb87ce912c405dbc612af0 /daemon/ntlm.c | |
parent | 80b0e2c0fdad108454ae87130496f595f0b81b81 (diff) |
- Changed 'method' to 'handler' throughout
- Fixed bug in hash.c with unitialized memory
- Imported new hash table features
- Writes out pid file when requested with -p option
Diffstat (limited to 'daemon/ntlm.c')
-rw-r--r-- | daemon/ntlm.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/daemon/ntlm.c b/daemon/ntlm.c index 85bee1d..37de9e8 100644 --- a/daemon/ntlm.c +++ b/daemon/ntlm.c @@ -581,6 +581,7 @@ int ntlm_init(ha_context_t* context) if(context) { ntlm_context_t* ctx = (ntlm_context_t*)(context->ctx_data); + hash_table_calls_t htc; ASSERT(ctx); @@ -604,13 +605,17 @@ int ntlm_init(ha_context_t* context) ASSERT(!ctx->established); /* Initialize our tables */ - if(!(ctx->pending = hash_create(NTLM_HASH_KEY_LEN, free_hash_object, NULL)) || - !(ctx->established = hash_create(NTLM_HASH_KEY_LEN, NULL, NULL))) + if(!(ctx->pending = hash_create(NTLM_HASH_KEY_LEN)) || + !(ctx->established = hash_create(NTLM_HASH_KEY_LEN))) { ha_messagex(LOG_CRIT, "out of memory"); return HA_CRITERROR; } + htc.f_freeval = free_hash_object; + htc.arg = NULL; + hash_set_table_calls(ctx->pending, &htc); + ha_messagex(LOG_INFO, "ntlm: initialized handler"); } |