mirror of
https://github.com/sheumann/hush.git
synced 2025-03-11 18:30:22 +00:00
Skip printing "/proc/%d/cmdline" stuff when it is not relevant
This commit is contained in:
parent
64191c3896
commit
fab3e12cec
@ -105,8 +105,8 @@ extern procps_status_t * procps_scan(int save_user_arg0)
|
|||||||
|
|
||||||
curstatus.rss <<= (PAGE_SHIFT - 10); /* 2**10 = 1kb */
|
curstatus.rss <<= (PAGE_SHIFT - 10); /* 2**10 = 1kb */
|
||||||
|
|
||||||
sprintf(status, "/proc/%d/cmdline", pid);
|
|
||||||
if(save_user_arg0) {
|
if(save_user_arg0) {
|
||||||
|
sprintf(status, "/proc/%d/cmdline", pid);
|
||||||
if((fp = fopen(status, "r")) == NULL)
|
if((fp = fopen(status, "r")) == NULL)
|
||||||
continue;
|
continue;
|
||||||
if((n=fread(buf, 1, sizeof(buf)-1, fp)) > 0) {
|
if((n=fread(buf, 1, sizeof(buf)-1, fp)) > 0) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user