summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/shared/hashmap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/hashmap.c b/src/shared/hashmap.c
index 2bc3b38739..5b329e0851 100644
--- a/src/shared/hashmap.c
+++ b/src/shared/hashmap.c
@@ -1810,7 +1810,7 @@ int set_consume(Set *s, void *value) {
int r;
r = set_put(s, value);
- if (r < 0)
+ if (r <= 0)
free(value);
return r;