datapath: Avoid sparse warning in compat header.
authorBen Pfaff <blp@nicira.com>
Mon, 24 Jan 2011 21:55:59 +0000 (13:55 -0800)
committerBen Pfaff <blp@nicira.com>
Tue, 25 Jan 2011 00:48:54 +0000 (16:48 -0800)
Without this change, sparse complains:

datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h:12:9: warning:
Using plain integer as NULL pointer

at least on kernels old enough to need this compat code anyway.  Might as
well suppress it, since it is easy.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
datapath/linux-2.6/compat-2.6/include/linux/rtnetlink.h

index b6bf7cb9e5ebe46ac1f732bb2bcc992f05ff3ac5..bb9bc379e59c23fcdf024e98178165d5015b1995 100644 (file)
@@ -9,7 +9,7 @@
 static inline void rtnl_notify(struct sk_buff *skb, u32 pid, u32 group,
                               struct nlmsghdr *nlh, gfp_t flags)
 {
-       BUG_ON(nlh);            /* not implemented */
+       BUG_ON(nlh != NULL);            /* not implemented */
        if (group) {
                /* errors reported via destination sk->sk_err */
                nlmsg_multicast(rtnl, skb, 0, group);