Page MenuHomeFreeBSD

D49153.diff
No OneTemporary

D49153.diff

diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c
--- a/sys/netinet/in_pcb.c
+++ b/sys/netinet/in_pcb.c
@@ -435,7 +435,7 @@
inp->inp_lport, &inp->inp_inc.inc_ie.ie_dependladdr,
INPCBLBGROUP_SIZMIN, numa_domain, fib);
if (grp == NULL)
- return (ENOBUFS);
+ return (ENOMEM);
in_pcblbgroup_insert(grp, inp);
CK_LIST_INSERT_HEAD(hdr, grp, il_list);
} else if (grp->il_inpcnt + grp->il_pendcnt == grp->il_inpsiz) {
@@ -449,7 +449,7 @@
/* Expand this local group. */
grp = in_pcblbgroup_resize(hdr, grp, grp->il_inpsiz * 2);
if (grp == NULL)
- return (ENOBUFS);
+ return (ENOMEM);
in_pcblbgroup_insert(grp, inp);
} else {
in_pcblbgroup_insert(grp, inp);
@@ -732,11 +732,12 @@
&inp->inp_lport, flags, cred);
if (error)
return (error);
- if (in_pcbinshash(inp) != 0) {
+ if (__predict_false((error = in_pcbinshash(inp)) != 0)) {
+ MPASS(inp->inp_socket->so_options & SO_REUSEPORT_LB);
inp->inp_laddr.s_addr = INADDR_ANY;
inp->inp_lport = 0;
inp->inp_flags &= ~INP_BOUNDFIB;
- return (EAGAIN);
+ return (error);
}
if (anonport)
inp->inp_flags |= INP_ANONPORT;

File Metadata

Mime Type
text/plain
Expires
Fri, Feb 28, 10:03 AM (19 h, 4 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16881075
Default Alt Text
D49153.diff (1 KB)

Event Timeline