git: ccac440f7cbb - main - libprocstat: style: space after switch
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 02 Oct 2023 21:50:52 UTC
The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=ccac440f7cbb013de41aa3933f3f7be77225c44f commit ccac440f7cbb013de41aa3933f3f7be77225c44f Author: Brooks Davis <brooks@FreeBSD.org> AuthorDate: 2023-10-02 21:50:00 +0000 Commit: Brooks Davis <brooks@FreeBSD.org> CommitDate: 2023-10-02 21:50:00 +0000 libprocstat: style: space after switch Style demands a space after the switch keyword. Noticed reviewing code in CheriBSD that propagated the style bug. Reported by: markj Sponsored by: DARPA Reviewed by: kib, markj Differential Revision: https://reviews.freebsd.org/D42041 --- lib/libprocstat/libprocstat.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/lib/libprocstat/libprocstat.c b/lib/libprocstat/libprocstat.c index 0af79b6e63a0..a302310dfb9a 100644 --- a/lib/libprocstat/libprocstat.c +++ b/lib/libprocstat/libprocstat.c @@ -347,7 +347,7 @@ struct filestat_list * procstat_getfiles(struct procstat *procstat, struct kinfo_proc *kp, int mmapped) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: return (procstat_getfiles_kvm(procstat, kp, mmapped)); case PROCSTAT_SYSCTL: @@ -1527,7 +1527,7 @@ procstat_get_socket_info_kvm(kvm_t *kd, struct filestat *fst, /* * Protocol specific data. */ - switch(dom.dom_family) { + switch (dom.dom_family) { case AF_INET: case AF_INET6: if (proto.pr_protocol == IPPROTO_TCP) { @@ -1600,7 +1600,7 @@ procstat_get_socket_info_sysctl(struct filestat *fst, struct sockstat *sock, /* * Protocol specific data. */ - switch(sock->dom_family) { + switch (sock->dom_family) { case AF_INET: case AF_INET6: if (sock->proto == IPPROTO_TCP) { @@ -1961,7 +1961,7 @@ procstat_getvmmap(struct procstat *procstat, struct kinfo_proc *kp, unsigned int *cntp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: warnx("kvm method is not supported"); return (NULL); @@ -2066,7 +2066,7 @@ gid_t * procstat_getgroups(struct procstat *procstat, struct kinfo_proc *kp, unsigned int *cntp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: return (procstat_getgroups_kvm(procstat->kd, kp, cntp)); case PROCSTAT_SYSCTL: @@ -2144,7 +2144,7 @@ int procstat_getumask(struct procstat *procstat, struct kinfo_proc *kp, unsigned short *maskp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: return (procstat_getumask_kvm(procstat->kd, kp, maskp)); case PROCSTAT_SYSCTL: @@ -2234,7 +2234,7 @@ int procstat_getrlimit(struct procstat *procstat, struct kinfo_proc *kp, int which, struct rlimit* rlimit) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: return (procstat_getrlimit_kvm(procstat->kd, kp, which, rlimit)); @@ -2293,7 +2293,7 @@ int procstat_getpathname(struct procstat *procstat, struct kinfo_proc *kp, char *pathname, size_t maxlen) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: /* XXX: Return empty string. */ if (maxlen > 0) @@ -2366,7 +2366,7 @@ procstat_getosrel_core(struct procstat_core *core, int *osrelp) int procstat_getosrel(struct procstat *procstat, struct kinfo_proc *kp, int *osrelp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: return (procstat_getosrel_kvm(procstat->kd, kp, osrelp)); case PROCSTAT_SYSCTL: @@ -2506,7 +2506,7 @@ Elf_Auxinfo * procstat_getauxv(struct procstat *procstat, struct kinfo_proc *kp, unsigned int *cntp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: warnx("kvm method is not supported"); return (NULL); @@ -2620,7 +2620,7 @@ struct kinfo_kstack * procstat_getkstack(struct procstat *procstat, struct kinfo_proc *kp, unsigned int *cntp) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: warnx("kvm method is not supported"); return (NULL); @@ -2749,7 +2749,7 @@ fail: struct advlock_list * procstat_getadvlock(struct procstat *procstat) { - switch(procstat->type) { + switch (procstat->type) { case PROCSTAT_KVM: warnx("kvm method is not supported"); return (NULL);