zygote: always log process exit reason.
Multiple people have run into problems where apps disappear without a
trace. Always log process exit, so that it's clear when a process is
intentionally exiting. (The amount of extraneous logging this generates
is probably minimal.)
Test: none
Change-Id: I77169da4d0f05dabfe38490757975ad7ad0247b2
diff --git a/core/jni/com_android_internal_os_Zygote.cpp b/core/jni/com_android_internal_os_Zygote.cpp
index cb53106..4953fd3 100644
--- a/core/jni/com_android_internal_os_Zygote.cpp
+++ b/core/jni/com_android_internal_os_Zygote.cpp
@@ -108,13 +108,9 @@
// changes its locking strategy or its use of syscalls within the
// lazy-init critical section, its use here may become unsafe.
if (WIFEXITED(status)) {
- if (WEXITSTATUS(status)) {
- ALOGI("Process %d exited cleanly (%d)", pid, WEXITSTATUS(status));
- }
+ ALOGI("Process %d exited cleanly (%d)", pid, WEXITSTATUS(status));
} else if (WIFSIGNALED(status)) {
- if (WTERMSIG(status) != SIGKILL) {
- ALOGI("Process %d exited due to signal (%d)", pid, WTERMSIG(status));
- }
+ ALOGI("Process %d exited due to signal (%d)", pid, WTERMSIG(status));
if (WCOREDUMP(status)) {
ALOGI("Process %d dumped core.", pid);
}