Put extra check in hashtable_fetch to return if zero entries (should never happen but will crash if not checked); remove dcb_close from mysql_backend where it closes backend DCBs, as these should be closed by the router.
This commit is contained in:
@ -379,7 +379,7 @@ hashtable_fetch(HASHTABLE *table, void *key)
|
||||
unsigned int hashkey;
|
||||
HASHENTRIES *entry;
|
||||
|
||||
if(table == NULL || key == NULL)
|
||||
if(table == NULL || key == NULL || 0 == table->hashsize)
|
||||
return NULL;
|
||||
|
||||
hashkey = table->hashfn(key) % table->hashsize;
|
||||
|
Reference in New Issue
Block a user