From: Stephen Hemminger Date: Mon, 14 Jul 2014 19:06:52 +0000 (-0700) Subject: ip: add paren to silence warning X-Git-Tag: v3.16.0~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1199c4f569175e09a33bf6b1af3a8faadbf9dc04;p=thirdparty%2Fiproute2.git ip: add paren to silence warning Gcc doesn't like mixed || and && in same conditional. --- diff --git a/ip/ipaddress.c b/ip/ipaddress.c index 8138e8626..8bb851197 100644 --- a/ip/ipaddress.c +++ b/ip/ipaddress.c @@ -1329,7 +1329,7 @@ void ipaddr_get_vf_rate(int vfnum, int *min, int *max, int idx) ifi = NLMSG_DATA(n); len = n->nlmsg_len - NLMSG_LENGTH(sizeof(*ifi)); - if (len < 0 || idx && idx != ifi->ifi_index) + if (len < 0 || (idx && idx != ifi->ifi_index)) continue; parse_rtattr(tb, IFLA_MAX, IFLA_RTA(ifi), len);