Nikolay Sivov : scrrun: Fix iterating through per-bucket pair list ( Valgrind).
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Apr 13 07:42:01 CDT 2015
Module: wine
Branch: master
Commit: 8ff3ab8503de51c8c4bd1b10c3e9c19ce181d352
URL: http://source.winehq.org/git/wine.git/?a=commit;h=8ff3ab8503de51c8c4bd1b10c3e9c19ce181d352
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Sat Apr 11 09:58:48 2015 +0300
scrrun: Fix iterating through per-bucket pair list (Valgrind).
---
dlls/scrrun/dictionary.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/scrrun/dictionary.c b/dlls/scrrun/dictionary.c
index 631d0b0..844b4d1 100644
--- a/dlls/scrrun/dictionary.c
+++ b/dlls/scrrun/dictionary.c
@@ -154,10 +154,11 @@ static struct keyitem_pair *get_keyitem_pair(dictionary *dict, VARIANT *key)
if (FAILED(hr))
return NULL;
- entry = head = get_bucket_head(dict, V_I4(&hash));
+ head = get_bucket_head(dict, V_I4(&hash));
if (!head->next || list_empty(head))
return NULL;
+ entry = list_head(head);
do {
pair = LIST_ENTRY(entry, struct keyitem_pair, bucket);
if (is_matching_key(dict, pair, key, V_I4(&hash))) return pair;
More information about the wine-cvs
mailing list