aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJacques Vidrine <nectar@FreeBSD.org>2003-01-07 15:17:41 +0000
committerJacques Vidrine <nectar@FreeBSD.org>2003-01-07 15:17:41 +0000
commita007fe609c70a839cd88560a30c8dc572e4f04d8 (patch)
tree388be8da78a063c52ac1cac9f64dc9c725495f4c
parent8e1904afc5ca9412e007b782047a4b34f22475c5 (diff)
downloadsrc-a007fe609c70a839cd88560a30c8dc572e4f04d8.tar.gz
src-a007fe609c70a839cd88560a30c8dc572e4f04d8.zip
MFC 1.114: Fix a file descriptor leak in fpathconf(2).
Notes
Notes: svn path=/releng/4.4/; revision=108880
-rw-r--r--UPDATING6
-rw-r--r--sys/conf/newvers.sh2
-rw-r--r--sys/kern/kern_descrip.c10
3 files changed, 13 insertions, 5 deletions
diff --git a/UPDATING b/UPDATING
index b2b3d79dcc8f..1822a600559b 100644
--- a/UPDATING
+++ b/UPDATING
@@ -17,6 +17,12 @@ minimal number of processes, if possible, for that patch. For those
updates that don't have an advisory, or to be safe, you can do a full
build and install as described in the COMMON ITEMS section.
+20030107: p32 FreeBSD-SA-02:44.filedesc
+ Correct a reference counting bug in fpathconf(2).
+
+20021122: p31 FreeBSD-SA-02:42.resolv
+ Correct a resolver overrun.
+
20021113: p30 FreeBSD-SA-02:43.bind
Correct name server vulnerabilities.
diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh
index c696e63ff982..3c641904d741 100644
--- a/sys/conf/newvers.sh
+++ b/sys/conf/newvers.sh
@@ -36,7 +36,7 @@
TYPE="FreeBSD"
REVISION="4.4"
-BRANCH="RELEASE-p31"
+BRANCH="RELEASE-p32"
RELEASE="${REVISION}-${BRANCH}"
VERSION="${TYPE} ${RELEASE}"
diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index 7a2a9b1b4bc8..934415d7ce37 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -712,10 +712,12 @@ fpathconf(p, uap)
switch (fp->f_type) {
case DTYPE_PIPE:
case DTYPE_SOCKET:
- if (uap->name != _PC_PIPE_BUF)
- return (EINVAL);
- p->p_retval[0] = PIPE_BUF;
- error = 0;
+ if (uap->name != _PC_PIPE_BUF) {
+ error = EINVAL;
+ } else {
+ p->p_retval[0] = PIPE_BUF;
+ error = 0;
+ }
break;
case DTYPE_FIFO:
case DTYPE_VNODE: