summaryrefslogtreecommitdiff
path: root/sys/kern/kern_proc.c
diff options
context:
space:
mode:
authorAntoine Brodin <antoine@FreeBSD.org>2018-01-01 21:25:01 +0000
committerAntoine Brodin <antoine@FreeBSD.org>2018-01-01 21:25:01 +0000
commit1b25176cbc60aae5c6749b0a98b52238c80a3d2a (patch)
treeccd75150a5bb6e6bd4868881df25eee2ecc470c2 /sys/kern/kern_proc.c
parent84874cc15114724a3f40d5461423ec60d846c028 (diff)
downloadsrc-test2-1b25176cbc60aae5c6749b0a98b52238c80a3d2a.tar.gz
src-test2-1b25176cbc60aae5c6749b0a98b52238c80a3d2a.zip
Notes
Diffstat (limited to 'sys/kern/kern_proc.c')
-rw-r--r--sys/kern/kern_proc.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/kern/kern_proc.c b/sys/kern/kern_proc.c
index 7334218be18a..723d82955006 100644
--- a/sys/kern/kern_proc.c
+++ b/sys/kern/kern_proc.c
@@ -1920,11 +1920,9 @@ sysctl_kern_proc_args(SYSCTL_HANDLER_ARGS)
* is nobody to modify pargs, thus we can just read.
*/
p = curproc;
- if (pid == p->p_pid && p->p_numthreads == 1 && req->newptr == NULL) {
- if ((pa = p->p_args) != NULL)
- error = SYSCTL_OUT(req, pa->ar_args, pa->ar_length);
- return (error);
- }
+ if (pid == p->p_pid && p->p_numthreads == 1 && req->newptr == NULL &&
+ (pa = p->p_args) != NULL)
+ return (SYSCTL_OUT(req, pa->ar_args, pa->ar_length));
flags = PGET_CANSEE;
if (req->newptr != NULL)