Date: Tue, 16 Dec 2008 03:18:59 +0000 (UTC) From: Kip Macy <kmacy@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r186164 - head/sys/netinet Message-ID: <200812160318.mBG3Ixf4025210@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kmacy Date: Tue Dec 16 03:18:59 2008 New Revision: 186164 URL: http://svn.freebsd.org/changeset/base/186164 Log: check pointer against NULL add new line after declaration for style Modified: head/sys/netinet/raw_ip.c Modified: head/sys/netinet/raw_ip.c ============================================================================== --- head/sys/netinet/raw_ip.c Tue Dec 16 03:12:44 2008 (r186163) +++ head/sys/netinet/raw_ip.c Tue Dec 16 03:18:59 2008 (r186164) @@ -280,7 +280,7 @@ rip_input(struct mbuf *m, int off) if (!prison_check_ip4(inp->inp_cred, &ip->ip_dst)) continue; } - if (last) { + if (last != NULL) { struct mbuf *n; n = m_copy(m, 0, (int)M_COPYALL); @@ -310,7 +310,7 @@ rip_input(struct mbuf *m, int off) if (!prison_check_ip4(inp->inp_cred, &ip->ip_dst)) continue; } - if (last) { + if (last != NULL) { struct mbuf *n; n = m_copy(m, 0, (int)M_COPYALL); @@ -964,6 +964,7 @@ rip_pcblist(SYSCTL_HANDLER_ARGS) INP_RLOCK(inp); if (inp->inp_gencnt <= gencnt) { struct xinpcb xi; + bzero(&xi, sizeof(xi)); xi.xi_len = sizeof xi; /* XXX should avoid extra copy */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200812160318.mBG3Ixf4025210>