diff options
author | phk <phk@FreeBSD.org> | 1994-10-02 17:35:40 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1994-10-02 17:35:40 +0000 |
commit | c3e49455410fee43dec92514e04dfed13eb8c587 (patch) | |
tree | 63e8cb7113791c7e2efaced539ff5283adf25d25 /sys/kern/kern_sysctl.c | |
parent | 29627a3d7d000aefc2860e1042707614018a2b57 (diff) | |
download | FreeBSD-src-c3e49455410fee43dec92514e04dfed13eb8c587.zip FreeBSD-src-c3e49455410fee43dec92514e04dfed13eb8c587.tar.gz |
All of this is cosmetic. prototypes, #includes, printfs and so on. Makes
GCC a lot more silent.
Diffstat (limited to 'sys/kern/kern_sysctl.c')
-rw-r--r-- | sys/kern/kern_sysctl.c | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c index 0b37159..2762929 100644 --- a/sys/kern/kern_sysctl.c +++ b/sys/kern/kern_sysctl.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)kern_sysctl.c 8.4 (Berkeley) 4/14/94 - * $Id: kern_sysctl.c,v 1.14 1994/09/21 03:46:46 wollman Exp $ + * $Id: kern_sysctl.c,v 1.15 1994/09/23 19:07:17 wollman Exp $ */ /* @@ -102,7 +102,8 @@ __sysctl(p, uap, retval) */ if (uap->namelen > CTL_MAXNAME || uap->namelen < 2) return (EINVAL); - if (error = copyin(uap->name, &name, uap->namelen * sizeof(int))) + error = copyin(uap->name, &name, uap->namelen * sizeof(int)); + if (error) return (error); switch (name[0]) { @@ -571,7 +572,8 @@ sysctl_file(where, sizep) *sizep = 0; return (0); } - if (error = copyout((caddr_t)&filehead, where, sizeof(filehead))) + error = copyout((caddr_t)&filehead, where, sizeof(filehead)); + if (error) return (error); buflen -= sizeof(filehead); where += sizeof(filehead); @@ -584,7 +586,8 @@ sysctl_file(where, sizep) *sizep = where - start; return (ENOMEM); } - if (error = copyout((caddr_t)fp, where, sizeof (struct file))) + error = copyout((caddr_t)fp, where, sizeof (struct file)); + if (error) return (error); buflen -= sizeof(struct file); where += sizeof(struct file); @@ -661,11 +664,13 @@ again: } if (buflen >= sizeof(struct kinfo_proc)) { fill_eproc(p, &eproc); - if (error = copyout((caddr_t)p, &dp->kp_proc, - sizeof(struct proc))) + error = copyout((caddr_t)p, &dp->kp_proc, + sizeof(struct proc)); + if (error) return (error); - if (error = copyout((caddr_t)&eproc, &dp->kp_eproc, - sizeof(eproc))) + error = copyout((caddr_t)&eproc, &dp->kp_eproc, + sizeof(eproc)); + if (error) return (error); dp++; buflen -= sizeof(struct kinfo_proc); |