mirror of
https://github.com/xzeldon/htop.git
synced 2024-12-23 22:55:46 +00:00
While we're at it, get rid of another sprintf.
This commit is contained in:
parent
b139671cbd
commit
52f814481c
@ -194,7 +194,7 @@ void Process_setupColumnWidths() {
|
||||
assert(digits < 20);
|
||||
for (int i = 0; Process_pidColumns[i].label; i++) {
|
||||
assert(i < 20);
|
||||
sprintf(Process_titleBuffer[i], "%*s ", digits, Process_pidColumns[i].label);
|
||||
snprintf(Process_titleBuffer[i], digits + 2, "%*s ", digits, Process_pidColumns[i].label);
|
||||
Process_fields[Process_pidColumns[i].id].title = Process_titleBuffer[i];
|
||||
}
|
||||
sprintf(Process_pidFormat, "%%%dd ", digits);
|
||||
|
Loading…
Reference in New Issue
Block a user