pidof: Do not memleak the contents of proc_t.

Just like "pgrep: Do not memleak the contents of proc_t."
This commit is contained in:
Qualys Security Advisory authored and Craig Small committed 2018-05-19 07:32:21 +10:00
1 parent 031bc56f65
commit 6f2f033142
1 file changed
-3
-3
View File
@@ -158,7 +158,6 @@ static void select_procs (void)
safe_free(root_link);
if (!match) { /* root check failed */
memset (&task, 0, sizeof (task));
continue;
}
}
@@ -233,8 +232,6 @@ static void select_procs (void)
}
}
memset (&task, 0, sizeof (task));
}
closeproc (ptp);