summaryrefslogtreecommitdiffstats
path: root/sys/kern/uipc_socket.c
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>1996-08-14 07:26:21 +0000
committerderaadt <deraadt@openbsd.org>1996-08-14 07:26:21 +0000
commit29bc08332a5711d8031ffa3429636a62a4018fdb (patch)
treec9c965099a0a33a46113b0763c76a4fe1d046dbc /sys/kern/uipc_socket.c
parentncheck -i would never show any information as it did not cache the directory (diff)
downloadwireguard-openbsd-29bc08332a5711d8031ffa3429636a62a4018fdb.tar.xz
wireguard-openbsd-29bc08332a5711d8031ffa3429636a62a4018fdb.zip
incorrect size calculation in mbuf copying, netbsd pr#2692; fix from explorer@flame.org
Diffstat (limited to 'sys/kern/uipc_socket.c')
-rw-r--r--sys/kern/uipc_socket.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c
index f5e27bc2ea1..6d0d9862a64 100644
--- a/sys/kern/uipc_socket.c
+++ b/sys/kern/uipc_socket.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uipc_socket.c,v 1.4 1996/08/05 01:00:53 deraadt Exp $ */
+/* $OpenBSD: uipc_socket.c,v 1.5 1996/08/14 07:26:21 deraadt Exp $ */
/* $NetBSD: uipc_socket.c,v 1.21 1996/02/04 02:17:52 christos Exp $ */
/*
@@ -427,7 +427,7 @@ restart:
} else
len = min(MCLBYTES, resid);
#endif
- space -= MCLBYTES;
+ space -= len;
} else {
nopages:
len = min(min(mlen, resid), space);