base/process: Use /proc/self/stat to read startup time.
After a new renderer task is cloned, CurrentProcessInfo::CreationTime
is called to compute the process startup time.
CurrentProcessInfo::CreationTime tries to read this information from
/proc/$PID/stat, where $PID is the current pid as self reported
by the new child process.
If the new task was cloned with CLONE_NEWPID, $PID will be in a different
namespace than the pid namespace represented in /proc, causing
CurrentProcessInfo::CreationTime to fail.
This CL changes CurrentProcessInfo::CreationTime so that it now
reads from /proc/self/stat instead of /proc/$PID/stat.
BUG=
TEST=Chrome now starts on intel cros devices even with DCHECKs enabled.
Review-Url: https://codereview.chromium.org/2715583002
Cr-Commit-Position: refs/heads/master@{#452588}
CrOS-Libchrome-Original-Commit: 4c25edcf92c0d4acccdc02f6f3a4a5264115e05c
3 files changed