summaryrefslogtreecommitdiffstats
path: root/share/man/man4/netintro.4
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2010-04-14 22:02:19 +0000
committerdelphij <delphij@FreeBSD.org>2010-04-14 22:02:19 +0000
commit58be1647f81d964462a1ca747976a7a85714fc0b (patch)
tree90f64aecec4946da4408301a264d15000ddf0f0d /share/man/man4/netintro.4
parentd7c34a15b8684c6d9333e40ee8de208dfd3ae3e3 (diff)
downloadFreeBSD-src-58be1647f81d964462a1ca747976a7a85714fc0b.zip
FreeBSD-src-58be1647f81d964462a1ca747976a7a85714fc0b.tar.gz
When an underlying ioctl(2) handler returns an error, our ioctl(2)
interface considers that it hits a fatal error, and will not copyout the request structure back for _IOW and _IOWR ioctls, keeping them untouched. The previous implementation of the SIOCGIFDESCR ioctl intends to feed the buffer length back to userland. However, if we return an error, the feedback would be defeated and ifconfig(8) would trap into an infinite loop. This commit changes SIOCGIFDESCR to set buffer field to NULL to indicate the previous ENAMETOOLONG case. Reported by: bschmidt MFC after: 2 weeks
Diffstat (limited to 'share/man/man4/netintro.4')
-rw-r--r--share/man/man4/netintro.49
1 files changed, 6 insertions, 3 deletions
diff --git a/share/man/man4/netintro.4 b/share/man/man4/netintro.4
index 348a13e..3e98940 100644
--- a/share/man/man4/netintro.4
+++ b/share/man/man4/netintro.4
@@ -32,7 +32,7 @@
.\" @(#)netintro.4 8.2 (Berkeley) 11/30/93
.\" $FreeBSD$
.\"
-.Dd January 26, 2010
+.Dd April 14, 2010
.Dt NETINTRO 4
.Os
.Sh NAME
@@ -292,8 +292,11 @@ field of
struct passed in as parameter, and the length would include
the terminating nul character.
If there is not enough space to hold the interface length,
-no copy would be done and an
-error would be returned.
+no copy would be done and the
+.Va buffer
+field of
+.Va ifru_buffer
+would be set to NULL.
The kernel will store the buffer length in the
.Va length
field upon return, regardless whether the buffer itself is
OpenPOWER on IntegriCloud