Whitespace cleanup.
This commit is contained in:
parent
45817aaa9c
commit
705916c692
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=122234
@ -184,7 +184,7 @@ parse(char *string)
|
|||||||
}
|
}
|
||||||
len = name2oid(bufp, mib);
|
len = name2oid(bufp, mib);
|
||||||
|
|
||||||
if (len < 0)
|
if (len < 0)
|
||||||
errx(1, "unknown oid '%s'", bufp);
|
errx(1, "unknown oid '%s'", bufp);
|
||||||
|
|
||||||
if (oidfmt(mib, len, fmt, &kind))
|
if (oidfmt(mib, len, fmt, &kind))
|
||||||
@ -218,7 +218,7 @@ parse(char *string)
|
|||||||
if (strlen(newval) == 0)
|
if (strlen(newval) == 0)
|
||||||
errx(1, "empty numeric value");
|
errx(1, "empty numeric value");
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (kind & CTLTYPE) {
|
switch (kind & CTLTYPE) {
|
||||||
case CTLTYPE_INT:
|
case CTLTYPE_INT:
|
||||||
intval = (int)strtol(newval, &endptr, 0);
|
intval = (int)strtol(newval, &endptr, 0);
|
||||||
@ -277,13 +277,13 @@ parse(char *string)
|
|||||||
putchar('\n');
|
putchar('\n');
|
||||||
switch (errno) {
|
switch (errno) {
|
||||||
case EOPNOTSUPP:
|
case EOPNOTSUPP:
|
||||||
errx(1, "%s: value is not available",
|
errx(1, "%s: value is not available",
|
||||||
string);
|
string);
|
||||||
case ENOTDIR:
|
case ENOTDIR:
|
||||||
errx(1, "%s: specification is incomplete",
|
errx(1, "%s: specification is incomplete",
|
||||||
string);
|
string);
|
||||||
case ENOMEM:
|
case ENOMEM:
|
||||||
errx(1, "%s: type is unknown to this program",
|
errx(1, "%s: type is unknown to this program",
|
||||||
string);
|
string);
|
||||||
default:
|
default:
|
||||||
warn("%s", string);
|
warn("%s", string);
|
||||||
@ -382,13 +382,13 @@ S_vmtotal(int l2, void *p)
|
|||||||
printf("Real Memory:\t\t(Total: %lldK Active %lldK)\n",
|
printf("Real Memory:\t\t(Total: %lldK Active %lldK)\n",
|
||||||
(long long)v->t_rm * pageKilo, (long long)v->t_arm * pageKilo);
|
(long long)v->t_rm * pageKilo, (long long)v->t_arm * pageKilo);
|
||||||
printf("Shared Virtual Memory:\t(Total: %lldK Active: %lldK)\n",
|
printf("Shared Virtual Memory:\t(Total: %lldK Active: %lldK)\n",
|
||||||
(long long)v->t_vmshr * pageKilo,
|
(long long)v->t_vmshr * pageKilo,
|
||||||
(long long)v->t_avmshr * pageKilo);
|
(long long)v->t_avmshr * pageKilo);
|
||||||
printf("Shared Real Memory:\t(Total: %lldK Active: %lldK)\n",
|
printf("Shared Real Memory:\t(Total: %lldK Active: %lldK)\n",
|
||||||
(long long)v->t_rmshr * pageKilo,
|
(long long)v->t_rmshr * pageKilo,
|
||||||
(long long)v->t_armshr * pageKilo);
|
(long long)v->t_armshr * pageKilo);
|
||||||
printf("Free Memory Pages:\t%ldK\n", (long long)v->t_free * pageKilo);
|
printf("Free Memory Pages:\t%ldK\n", (long long)v->t_free * pageKilo);
|
||||||
|
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -453,7 +453,7 @@ name2oid(char *name, int *oidp)
|
|||||||
|
|
||||||
j = CTL_MAXNAME * sizeof(int);
|
j = CTL_MAXNAME * sizeof(int);
|
||||||
i = sysctl(oid, 2, oidp, &j, name, strlen(name));
|
i = sysctl(oid, 2, oidp, &j, name, strlen(name));
|
||||||
if (i < 0)
|
if (i < 0)
|
||||||
return i;
|
return i;
|
||||||
j /= sizeof(int);
|
j /= sizeof(int);
|
||||||
return (j);
|
return (j);
|
||||||
@ -556,7 +556,7 @@ show_var(int *oid, int nlen)
|
|||||||
printf("%s%s", name, sep);
|
printf("%s%s", name, sep);
|
||||||
printf("%.*s", len, p);
|
printf("%.*s", len, p);
|
||||||
return (0);
|
return (0);
|
||||||
|
|
||||||
case 'I':
|
case 'I':
|
||||||
if (!nflag)
|
if (!nflag)
|
||||||
printf("%s%s", name, sep);
|
printf("%s%s", name, sep);
|
||||||
|
Loading…
Reference in New Issue
Block a user