diff options
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/execute.c | 6 | ||||
-rw-r--r-- | src/core/main.c | 9 |
2 files changed, 9 insertions, 6 deletions
diff --git a/src/core/execute.c b/src/core/execute.c index 0028730889..d70ba2be17 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -991,14 +991,8 @@ fail: } strv_free(e); - closelog(); - if (pam_pid > 1) { - kill(pam_pid, SIGTERM); - kill(pam_pid, SIGCONT); - } - return err; } #endif diff --git a/src/core/main.c b/src/core/main.c index 2f9094f03a..27ba6af031 100644 --- a/src/core/main.c +++ b/src/core/main.c @@ -1968,6 +1968,15 @@ finish: (void) clearenv(); assert(i <= args_size); + + /* + * We want valgrind to print its memory usage summary before reexecution. + * Valgrind won't do this is on its own on exec(), but it will do it on exit(). + * Hence, to ensure we get a summary here, fork() off a child, let it exit() cleanly, + * so that it prints the summary, and wait() for it in the parent, before proceeding into the exec(). + */ + valgrind_summary_hack(); + (void) execv(args[0], (char* const*) args); } |