summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authortedu <tedu@openbsd.org>2003-05-06 20:35:14 +0000
committertedu <tedu@openbsd.org>2003-05-06 20:35:14 +0000
commit139b124d2edcf8927e27800c3a7eb1a724a8c64e (patch)
treee371ba1deb1b45685f8b6e432baf9d70b28f74fa /sys
parentKNF while I'm here (diff)
downloadwireguard-openbsd-139b124d2edcf8927e27800c3a7eb1a724a8c64e.tar.xz
wireguard-openbsd-139b124d2edcf8927e27800c3a7eb1a724a8c64e.zip
use M_NOWAIT instead of WAITOK for the hashtable allocation. ok itojun@
Diffstat (limited to 'sys')
-rw-r--r--sys/netinet/in_pcb.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c
index e53c42a7399..5e8851b3030 100644
--- a/sys/netinet/in_pcb.c
+++ b/sys/netinet/in_pcb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in_pcb.c,v 1.64 2002/09/11 03:15:36 itojun Exp $ */
+/* $OpenBSD: in_pcb.c,v 1.65 2003/05/06 20:35:14 tedu Exp $ */
/* $NetBSD: in_pcb.c,v 1.25 1996/02/13 23:41:53 christos Exp $ */
/*
@@ -128,7 +128,9 @@ in_pcbinit(table, hashsize)
{
CIRCLEQ_INIT(&table->inpt_queue);
- table->inpt_hashtbl = hashinit(hashsize, M_PCB, M_WAITOK, &table->inpt_hash);
+ table->inpt_hashtbl = hashinit(hashsize, M_PCB, M_NOWAIT, &table->inpt_hash);
+ if (table->inpt_hashtbl == NULL)
+ panic("in_pcbinit: hashinit failed");
table->inpt_lastport = 0;
}