artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
74b0625
)
do not allow SO_SNDBUF/SO_RCVBUF len 0
author
deraadt
<deraadt@openbsd.org>
Fri, 21 Feb 1997 08:45:00 +0000
(08:45 +0000)
committer
deraadt
<deraadt@openbsd.org>
Fri, 21 Feb 1997 08:45:00 +0000
(08:45 +0000)
sys/kern/uipc_socket2.c
patch
|
blob
|
history
diff --git
a/sys/kern/uipc_socket2.c
b/sys/kern/uipc_socket2.c
index
92ab13d
..
1641822
100644
(file)
--- a/
sys/kern/uipc_socket2.c
+++ b/
sys/kern/uipc_socket2.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: uipc_socket2.c,v 1.
4 1996/09/20 22:53:1
0 deraadt Exp $ */
+/* $OpenBSD: uipc_socket2.c,v 1.
5 1997/02/21 08:45:0
0 deraadt Exp $ */
/* $NetBSD: uipc_socket2.c,v 1.11 1996/02/04 02:17:55 christos Exp $ */
/*
@@
-397,7
+397,7
@@
sbreserve(sb, cc)
u_long cc;
{
- if (cc > sb_max * MCLBYTES / (MSIZE + MCLBYTES))
+ if (cc
== 0 || cc
> sb_max * MCLBYTES / (MSIZE + MCLBYTES))
return (0);
sb->sb_hiwat = cc;
sb->sb_mbmax = min(cc * 2, sb_max);