diff options
Diffstat (limited to 'src/libsystem/proc.c')
-rw-r--r-- | src/libsystem/proc.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libsystem/proc.c b/src/libsystem/proc.c index acac082..0881ae8 100644 --- a/src/libsystem/proc.c +++ b/src/libsystem/proc.c @@ -25,12 +25,7 @@ #include "libsystem.h" -/* In old kernel, this symbol maybe NOT */ -#ifndef TASK_COMM_LEN -#define TASK_COMM_LEN 16 -#endif - -ssize_t cmdline_get_str(char **buf, const char *op) { +ssize_t proc_cmdline_get_str(char **buf, const char *op) { _cleanup_free_ char *cmdline = NULL; char *s, *w, *state; size_t l, ll; @@ -60,7 +55,12 @@ ssize_t cmdline_get_str(char **buf, const char *op) { return -ENOENT; } -int pid_of(const char *pname) { +/* In old kernel, this symbol maybe NOT */ +#ifndef TASK_COMM_LEN +#define TASK_COMM_LEN 16 +#endif + +int proc_pid_of(const char *pname) { _cleanup_closedir_ DIR *dir = NULL; struct dirent *de; int r; |