From 6dc485dd20ae2fb1684d965bb9a650ee5b15500a Mon Sep 17 00:00:00 2001 From: Benny Baumann Date: Tue, 2 Feb 2021 00:13:19 +0100 Subject: Remove duplicate field LinuxProcess->procCmdlineBasenameEnd This field held practically the same value as cmdlineBasenameEnd --- linux/LinuxProcessList.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'linux/LinuxProcessList.c') diff --git a/linux/LinuxProcessList.c b/linux/LinuxProcessList.c index 97ba9cc0..128b0a27 100644 --- a/linux/LinuxProcessList.c +++ b/linux/LinuxProcessList.c @@ -1133,10 +1133,9 @@ static bool LinuxProcessList_readCmdlineFile(Process* process, openat_arg_t proc LinuxProcess *lp = (LinuxProcess *)process; lp->mergedCommand.maxLen = lastChar + 1; /* accommodate cmdline */ if (!process->cmdline || !String_eq(command, process->cmdline)) { - process->cmdlineBasenameOffset = tokenEnd; free_and_xStrdup(&process->cmdline, command); lp->procCmdlineBasenameOffset = tokenStart; - lp->procCmdlineBasenameEnd = tokenEnd; + process->cmdlineBasenameOffset = tokenEnd; lp->mergedCommand.cmdlineChanged = true; } @@ -1465,14 +1464,12 @@ static bool LinuxProcessList_recurseProcTree(LinuxProcessList* this, openat_arg_ proc->cmdlineBasenameOffset = -1; free_and_xStrdup(&proc->cmdline, command); lp->procCmdlineBasenameOffset = 0; - lp->procCmdlineBasenameEnd = 0; lp->mergedCommand.commChanged = true; } else if (Process_isThread(proc)) { if (settings->showThreadNames || Process_isKernelThread(proc)) { proc->cmdlineBasenameOffset = -1; free_and_xStrdup(&proc->cmdline, command); lp->procCmdlineBasenameOffset = 0; - lp->procCmdlineBasenameEnd = 0; lp->mergedCommand.commChanged = true; } -- cgit v1.2.3