process: Make sure Linux always parses cmdline.

This commit is contained in:
Alastair Poole 2020-05-09 00:14:30 +01:00
parent fc60c351ca
commit a80d244476
1 changed files with 16 additions and 18 deletions

View File

@ -177,8 +177,7 @@ _cmd_args(Proc_Info *p, int pid, char *name, size_t len)
snprintf(name, len, "%s", ecore_file_file_get(link));
free(link);
}
else
{
FILE *f = fopen(eina_slstr_printf("/proc/%d/cmdline", pid), "r");
if (f)
{
@ -200,7 +199,6 @@ _cmd_args(Proc_Info *p, int pid, char *name, size_t len)
}
fclose(f);
}
}
char *end = strchr(name, ' ');
if (end) *end = '\0';