Add the percent sign to *_perc functions

Units should be added to the corresponding numbers
This commit is contained in:
Aaron Marcher
2018-05-19 20:33:06 +02:00
parent 68a3902dc5
commit 74c4f4ebda
7 changed files with 12 additions and 12 deletions

View File

@ -28,7 +28,7 @@
"MemAvailable: %ld kB\nBuffers: %ld kB\n"
"Cached: %ld kB\n",
&total, &free, &buffers, &buffers, &cached) == 5) ?
bprintf("%d", 100 * ((total - free) - (buffers + cached)) /
bprintf("%d%%", 100 * ((total - free) - (buffers + cached)) /
total) :
NULL;
}
@ -97,7 +97,7 @@
if (load_uvmexp(&uvmexp)) {
percent = uvmexp.active * 100 / uvmexp.npages;
return bprintf("%d", percent);
return bprintf("%d%%", percent);
}
return NULL;