summaryrefslogtreecommitdiff
path: root/ecp/src
diff options
context:
space:
mode:
Diffstat (limited to 'ecp/src')
-rwxr-xr-xecp/src/ecp/htable/hashtable.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ecp/src/ecp/htable/hashtable.c b/ecp/src/ecp/htable/hashtable.c
index 13ed68c..f6d3a0b 100755
--- a/ecp/src/ecp/htable/hashtable.c
+++ b/ecp/src/ecp/htable/hashtable.c
@@ -302,7 +302,8 @@ hashtable_remove_kv_static(struct hashtable *h, void *k, void *v)
e = *pE;
while (NULL != e)
{
- if (v == e->v)
+ /* Check hash value to short circuit heavier comparison */
+ if ((hashvalue == e->h) && (h->eqfn(k, e->k)) && (v == e->v))
{
*pE = e->next;
h->entrycount--;