aboutsummaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_descrip.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/kern_descrip.c')
-rw-r--r--sys/kern/kern_descrip.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index c2db5a4cffe9..50888ce6820a 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -711,10 +711,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: