[asterisk-commits] mmichelson: branch 12 r403349 - /branches/12/res/res_pjsip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Dec 4 12:40:26 CST 2013


Author: mmichelson
Date: Wed Dec  4 12:40:23 2013
New Revision: 403349

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=403349
Log:
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.


Modified:
    branches/12/res/res_pjsip.c

Modified: branches/12/res/res_pjsip.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/res/res_pjsip.c?view=diff&rev=403349&r1=403348&r2=403349
==============================================================================
--- branches/12/res/res_pjsip.c (original)
+++ branches/12/res/res_pjsip.c Wed Dec  4 12:40:23 2013
@@ -1937,7 +1937,7 @@
 
 void *ast_sip_dict_get(void *ht, const char *key)
 {
-	unsigned int hval;
+	unsigned int hval = 0;
 
 	if (!ht) {
 		return NULL;




More information about the asterisk-commits mailing list