mirror of
https://git.suyu.dev/suyu/AppImageKit-checkrt.git
synced 2025-12-23 15:54:10 +01:00
I don't know why, but getppid() returns wrong result for me when application is started
This commit is contained in:
parent
07e851fcc8
commit
b2ac83a76e
4 changed files with 40 additions and 7 deletions
2
exec.c
2
exec.c
|
|
@ -79,7 +79,7 @@ static int exec_common(execve_func_t function, const char *filename, char* const
|
|||
DEBUG("filename %s, fullpath %s\n", filename, fullpath);
|
||||
char* const *env = envp;
|
||||
if (is_external_process(fullpath)) {
|
||||
DEBUG("External process detected. Restoring env vars from parent %d\n", getppid());
|
||||
DEBUG("External process detected. Restoring env vars from parent %d\n", get_parent_pid());
|
||||
env = read_parent_env();
|
||||
if (!env)
|
||||
env = envp;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue