diff options
author | rohitrao@chromium.org <rohitrao@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-04 03:36:11 +0000 |
---|---|---|
committer | rohitrao@chromium.org <rohitrao@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-04 03:36:11 +0000 |
commit | a112bdbcca06d33f07ea66042a32e57f65fb2b69 (patch) | |
tree | 2c6c258f125ddc19ee2478591c8c06c8b1117b49 /base | |
parent | bb6ea27363f946300a06ffed219ab625fc199758 (diff) | |
download | chromium_src-a112bdbcca06d33f07ea66042a32e57f65fb2b69.zip chromium_src-a112bdbcca06d33f07ea66042a32e57f65fb2b69.tar.gz chromium_src-a112bdbcca06d33f07ea66042a32e57f65fb2b69.tar.bz2 |
Adds logging into fork_and_get_task() to test a hypothesis on why WaitForInitialLoads() is failing.
Will be reverted soon.
BUG=None
TEST=None
Review URL: http://codereview.chromium.org/3353012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@58576 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base')
-rw-r--r-- | base/process_util_posix.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/base/process_util_posix.cc b/base/process_util_posix.cc index 8fe64d0..2e9d112 100644 --- a/base/process_util_posix.cc +++ b/base/process_util_posix.cc @@ -327,11 +327,13 @@ static pid_t fork_and_get_task(task_t* child_task) { // return a valid pid. If IPC fails in the child, the parent will have to wait // until kTimeoutMs is over. This is not optimal, but I've never seen it // happen, and stuff should still mostly work. + LOG(ERROR) << "fork_and_get_task() about to fork"; pid_t pid = fork(); switch (pid) { case -1: return pid; case 0: { // child + LOG(ERROR) << "fork_and_get_task() I'm the child!"; // Must reset signal handlers before doing any mach IPC, as the mach IPC // calls can potentially hang forever. ResetChildSignalHandlersToDefaults(); @@ -341,15 +343,19 @@ static pid_t fork_and_get_task(task_t* child_task) { return pid; } + LOG(ERROR) << "fork_and_get_task() child creating sender port"; MachPortSender child_sender(mach_connection_name.c_str()); + LOG(ERROR) << "fork_and_get_task() child done creating sender port"; err = child_sender.SendMessage(child_message, kTimeoutMs); if (err != KERN_SUCCESS) { LOG(ERROR) << "child SendMessage() failed: " << MachErrorCode(err); return pid; } + LOG(ERROR) << "fork_and_get_task() Sent a message to my parent"; break; } default: { // parent + LOG(ERROR) << "fork_and_get_task() I'm the parent!"; MachReceiveMessage child_message; err = parent_recv_port.WaitForMessage(&child_message, kTimeoutMs); if (err != KERN_SUCCESS) { @@ -362,6 +368,7 @@ static pid_t fork_and_get_task(task_t* child_task) { return pid; } *child_task = child_message.GetTranslatedPort(0); + LOG(ERROR) << "fork_and_get_task() Got a message from the child"; break; } } |