diff options
author | Jakub Filak <jfilak@redhat.com> | 2014-11-19 11:01:19 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2014-11-21 00:32:02 +0100 |
commit | ad450c3e0418fe23e2896e581575cb06564ca29a (patch) | |
tree | 3f85df33ef5f286f750f904c5b6dc05aa336c838 /src/shared/util.h | |
parent | 1c6eb4e36bf88015d0bbe8fae417622e6132b864 (diff) |
util: add functions getting proc cwd and root
/proc/[pid]/cwd and /proc/[pid]/root are symliks to corresponding
directories
The added functions returns values of that symlinks.
Diffstat (limited to 'src/shared/util.h')
-rw-r--r-- | src/shared/util.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/shared/util.h b/src/shared/util.h index 835fee496d..fc59481b99 100644 --- a/src/shared/util.h +++ b/src/shared/util.h @@ -295,6 +295,8 @@ int get_process_exe(pid_t pid, char **name); int get_process_uid(pid_t pid, uid_t *uid); int get_process_gid(pid_t pid, gid_t *gid); int get_process_capeff(pid_t pid, char **capeff); +int get_process_cwd(pid_t pid, char **cwd); +int get_process_root(pid_t pid, char **root); char hexchar(int x) _const_; int unhexchar(char c) _const_; |