This is an automated email from the ASF dual-hosted git repository. gnutt pushed a commit to branch pr807 in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 0c630d79f9d3e2630983ff40c0da98c7d7fef9a4 Author: Xiang Xiao <[email protected]> AuthorDate: Thu Apr 16 13:50:20 2020 +0800 netlink: Fix the compiler warning in netlink_add_broadcast netlink/netlink_conn.c: In function 'netlink_add_broadcast': netlink/netlink_conn.c:319:45: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses] 319 | if (conn->groups & (1 << (group - 1)) == 0) | ~~~~~~~~~~~~~~~~~~~^~~~ Signed-off-by: Xiang Xiao <[email protected]> Change-Id: I1bee7933dca1bdd118d0034a564b4306e1ae5684 --- net/netlink/netlink_conn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/netlink/netlink_conn.c b/net/netlink/netlink_conn.c index 9145ef2..96aed71 100644 --- a/net/netlink/netlink_conn.c +++ b/net/netlink/netlink_conn.c @@ -317,7 +317,7 @@ void netlink_add_broadcast(int group, FAR struct netlink_response_s *data) while ((conn = netlink_nextconn(conn)) != NULL) { - if (conn->groups & (1 << (group - 1)) == 0) + if ((conn->groups & (1 << (group - 1))) == 0) { continue; }
