aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2015-03-29 15:36:08 -0400
committerMike Frysinger <vapier@gentoo.org>2015-03-29 15:36:08 -0400
commit7d364f3f20e74aab152288d92cef1e0bba513240 (patch)
tree59252c5ef4d9b097edef04e1d3e660bdd4c37077
parentbuild: link against gnulib (diff)
downloadpax-utils-7d364f3f20e74aab152288d92cef1e0bba513240.tar.gz
pax-utils-7d364f3f20e74aab152288d92cef1e0bba513240.tar.bz2
pax-utils-7d364f3f20e74aab152288d92cef1e0bba513240.zip
scanelf: add paren to quiet new gcc-5 warningv1.0.3
Newer gcc versions throw a warning on code that is written how we want (comparing the result of !strcmp to a variable). Add a set of paren to make gcc happy. scanelf.c: In function 'scanelf_file_needed_lib': scanelf.c:1083:43: warning: logical not is only applied to the left hand side of comparison [-Wlogical-not-parentheses] if (!strcmp(find_lib_name, needed) == invert) \ ^
-rw-r--r--scanelf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/scanelf.c b/scanelf.c
index a50b6e4..7219f1c 100644
--- a/scanelf.c
+++ b/scanelf.c
@@ -1080,7 +1080,7 @@ static const char *scanelf_file_needed_lib(elfobj *elf, char *found_needed, char
int invert = 1; \
if (find_lib_name[0] == '!') \
invert = 0, ++find_lib_name; \
- if (!strcmp(find_lib_name, needed) == invert) \
+ if ((!strcmp(find_lib_name, needed)) == invert) \
++matched; \
} \
\