From: Daniel Mack Date: Tue, 24 Feb 2015 15:24:14 +0000 (+0100) Subject: test-hashmap: fix gcc5 warning X-Git-Tag: v219.0~593 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=4b3eff61640672bf0b19cb8cdd88ce5e84dcda1c;p=elogind.git test-hashmap: fix gcc5 warning gcc5 spits out a warning about test-hashmap.c: CC src/test/test-hashmap.o src/test/test-hashmap.c: In function ‘test_string_compare_func’: src/test/test-hashmap.c:76:79: warning: logical not is only applied to the left hand side of comparison [-Wlogical-not-parentheses] --- diff --git a/src/test/test-hashmap.c b/src/test/test-hashmap.c index 40be084ff..767cbd90e 100644 --- a/src/test/test-hashmap.c +++ b/src/test/test-hashmap.c @@ -73,7 +73,7 @@ static void test_trivial_compare_func(void) { } static void test_string_compare_func(void) { - assert_se(!string_compare_func("fred", "wilma") == 0); + assert_se(string_compare_func("fred", "wilma") != 0); assert_se(string_compare_func("fred", "fred") == 0); }