]> granicus.if.org Git - procps-ng/commit
library: revert changes to 'look_up_our_self' function
authorJim Warner <james.warner@comcast.net>
Sun, 23 Aug 2015 05:00:00 +0000 (00:00 -0500)
committerCraig Small <csmall@enc.com.au>
Wed, 26 Aug 2015 12:42:02 +0000 (22:42 +1000)
commite949b78c30d949f4789db5d798c3179849ed688c
treec2693e6f954d026f403e187dea3ffeb48281daae
parent64238730fa45e92bc40b2aa28d107c2469ac29e9
library: revert changes to 'look_up_our_self' function

The patch below is where most proc_t fixed size arrays
became simple pointers to char. In that commit changes
to the above function were made so that dynamic memory
was freed which included the program name (cmd) field.

That change was prompted by a valgrind reported memory
leak during development that no longer seems to exist.
However, by keeping the look_up_our_self() changes the
ps command without args then fails to report anything.

So this patch just restores the expected old behavior.

Reference(s):
commit 3881a0844afe4d1b3cd512b2c2fd79e11bb0ed06

Signed-off-by: Jim Warner <james.warner@comcast.net>
proc/readproc.c