mirror of
https://github.com/xzeldon/htop.git
synced 2025-01-31 09:07:25 +03:00
Release memory for cmdline when Process_updateCmdline() returns.
This closes a nasty memory leak. There is at least another leak looming somewhere when Disk I/O is shown in the header area. That could very well be an issue within libdevstat native to FreeBSD.
This commit is contained in:
parent
970885edc3
commit
9eb52d5932
@ -444,6 +444,8 @@ static void FreeBSDProcessList_updateProcessName(kvm_t* kd, const struct kinfo_p
|
||||
*at = '\0';
|
||||
|
||||
Process_updateCmdline(proc, cmdline, 0, end);
|
||||
|
||||
free(cmdline);
|
||||
}
|
||||
|
||||
static char* FreeBSDProcessList_readJailName(const struct kinfo_proc* kproc) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user