From d61f258384a8fb0f03d09872d5d108bda115c61a Mon Sep 17 00:00:00 2001 From: Mark Michelson Date: Wed, 4 Dec 2013 18:41:01 +0000 Subject: [PATCH] Initialize the hash value argument to pj_hash_get() to 0. Passing a non-zero value causes PJLIB to use the given input as the hash value. Passing zero causes the parameter to become an output parameter that receives the hash value that was computed based on the given key. This change essentially makes ast_sip_dict_get() properly retrieve the desired value. ........ Merged revisions 403349 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403350 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- res/res_pjsip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/res/res_pjsip.c b/res/res_pjsip.c index 80cef06e55..d5b870f1f2 100644 --- a/res/res_pjsip.c +++ b/res/res_pjsip.c @@ -1937,7 +1937,7 @@ int ast_sip_thread_is_servant(void) void *ast_sip_dict_get(void *ht, const char *key) { - unsigned int hval; + unsigned int hval = 0; if (!ht) { return NULL;