| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/common/child_thread.h" | 5 #include "chrome/common/child_thread.h" |
| 6 | 6 |
| 7 #include "base/string_util.h" | 7 #include "base/string_util.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "chrome/common/child_process.h" | 9 #include "chrome/common/child_process.h" |
| 10 #include "chrome/common/chrome_switches.h" | 10 #include "chrome/common/chrome_switches.h" |
| 11 #include "chrome/common/ipc_logging.h" | |
| 12 #include "chrome/common/plugin_messages.h" | 11 #include "chrome/common/plugin_messages.h" |
| 12 #include "ipc/ipc_logging.h" |
| 13 #include "webkit/glue/webkit_glue.h" | 13 #include "webkit/glue/webkit_glue.h" |
| 14 | 14 |
| 15 | 15 |
| 16 // V8 needs a 1MB stack size. | 16 // V8 needs a 1MB stack size. |
| 17 const size_t ChildThread::kV8StackSize = 1024 * 1024; | 17 const size_t ChildThread::kV8StackSize = 1024 * 1024; |
| 18 | 18 |
| 19 ChildThread::ChildThread(Thread::Options options) | 19 ChildThread::ChildThread(Thread::Options options) |
| 20 : Thread("Chrome_ChildThread"), | 20 : Thread("Chrome_ChildThread"), |
| 21 owner_loop_(MessageLoop::current()), | 21 owner_loop_(MessageLoop::current()), |
| 22 options_(options), | 22 options_(options), |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 owner_loop_->PostTask(FROM_HERE, new MessageLoop::QuitTask()); | 117 owner_loop_->PostTask(FROM_HERE, new MessageLoop::QuitTask()); |
| 118 return; | 118 return; |
| 119 } | 119 } |
| 120 | 120 |
| 121 // The child process shutdown sequence is a request response based mechanism, | 121 // The child process shutdown sequence is a request response based mechanism, |
| 122 // where we send out an initial feeler request to the child process host | 122 // where we send out an initial feeler request to the child process host |
| 123 // instance in the browser to verify if it's ok to shutdown the child process. | 123 // instance in the browser to verify if it's ok to shutdown the child process. |
| 124 // The browser then sends back a response if it's ok to shutdown. | 124 // The browser then sends back a response if it's ok to shutdown. |
| 125 Send(new PluginProcessHostMsg_ShutdownRequest); | 125 Send(new PluginProcessHostMsg_ShutdownRequest); |
| 126 } | 126 } |
| OLD | NEW |