From: Lukas Nykryn Date: Thu, 23 Aug 2012 10:21:55 +0000 (+0200) Subject: hashmap: hashmap_contains does not need hashmap_entry X-Git-Tag: v190~196 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9f89986d2beb2c45436cc9e5b4da8bd4a79f100c;p=platform%2Fupstream%2Fsystemd.git hashmap: hashmap_contains does not need hashmap_entry --- diff --git a/src/shared/hashmap.c b/src/shared/hashmap.c index be37a36..0a044b8 100644 --- a/src/shared/hashmap.c +++ b/src/shared/hashmap.c @@ -380,14 +380,13 @@ void* hashmap_get(Hashmap *h, const void *key) { bool hashmap_contains(Hashmap *h, const void *key) { unsigned hash; - struct hashmap_entry *e; if (!h) return false; hash = h->hash_func(key) % NBUCKETS; - if (!(e = hash_scan(h, hash, key))) + if (!hash_scan(h, hash, key)) return false; return true;