diff options
author | wollman <wollman@FreeBSD.org> | 1995-02-16 01:47:36 +0000 |
---|---|---|
committer | wollman <wollman@FreeBSD.org> | 1995-02-16 01:47:36 +0000 |
commit | b834398cc6b2093da3fd2e48d35d8ec380000931 (patch) | |
tree | 8c9e80a3018846c943be9b26dd00fd32615aa8a3 /sys | |
parent | a5efc621269eaed70a3bc51b461b4bf8dbc3ff82 (diff) | |
download | FreeBSD-src-b834398cc6b2093da3fd2e48d35d8ec380000931.zip FreeBSD-src-b834398cc6b2093da3fd2e48d35d8ec380000931.tar.gz |
spl back down in unusual out-of-memory condition in udp_output().
Obtained from: Stevens, vol. 2, exercise 23.4 (solution p. 1083)
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/udp_usrreq.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index ee62439..2c6f004 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)udp_usrreq.c 8.4 (Berkeley) 1/21/94 - * $Id: udp_usrreq.c,v 1.5 1995/02/16 00:27:46 wollman Exp $ + * $Id: udp_usrreq.c,v 1.6 1995/02/16 01:25:06 wollman Exp $ */ #include <sys/param.h> @@ -420,6 +420,8 @@ udp_output(inp, m, addr, control) M_PREPEND(m, sizeof(struct udpiphdr), M_DONTWAIT); if (m == 0) { error = ENOBUFS; + if (addr) + splx(s); goto release; } |