diff options
author | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-11-29 18:30:49 +0000 |
---|---|---|
committer | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-11-29 18:30:49 +0000 |
commit | c53216dac5f9599ba08eac88e5d36b8d7961a5a0 (patch) | |
tree | 0f2e5970298ec09551588b23667c9c8489fbe077 /sys/netinet/udp_usrreq.c | |
parent | e853941b9b4501ec09ef580ccc0de940b24dc8c3 (diff) |
Document inp_socket as immutable and remove NULL checks.
Struct inpcb field inp_socket is initialized in in_pcballoc(). It
is not NULL and never changed.
OK mvs@
Diffstat (limited to 'sys/netinet/udp_usrreq.c')
-rw-r--r-- | sys/netinet/udp_usrreq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index f4250a833ce..6c40f766a21 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -1,4 +1,4 @@ -/* $OpenBSD: udp_usrreq.c,v 1.309 2023/11/28 13:23:20 bluhm Exp $ */ +/* $OpenBSD: udp_usrreq.c,v 1.310 2023/11/29 18:30:48 bluhm Exp $ */ /* $NetBSD: udp_usrreq.c,v 1.28 1996/03/16 23:54:03 christos Exp $ */ /* @@ -898,7 +898,7 @@ udp_ctlinput(int cmd, struct sockaddr *sa, u_int rdomain, void *v) inp = in_pcblookup(&udbtable, ip->ip_dst, uhp->uh_dport, ip->ip_src, uhp->uh_sport, rdomain); - if (inp && inp->inp_socket != NULL) + if (inp != NULL) notify(inp, errno); in_pcbunref(inp); } else |