Merge "Log the errno if calling fork() fails"
This commit is contained in:
@@ -2127,6 +2127,8 @@ pid_t zygote::ForkCommon(JNIEnv* env, bool is_system_server,
|
|||||||
|
|
||||||
// Reset the fd to the unsolicited zygote socket
|
// Reset the fd to the unsolicited zygote socket
|
||||||
gSystemServerSocketFd = -1;
|
gSystemServerSocketFd = -1;
|
||||||
|
} else if (pid == -1) {
|
||||||
|
ALOGE("Failed to fork child process: %s (%d)", strerror(errno), errno);
|
||||||
} else {
|
} else {
|
||||||
ALOGD("Forked child process %d", pid);
|
ALOGD("Forked child process %d", pid);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user