diff options
Diffstat (limited to 'chrome_frame/chrome_frame_automation.cc')
-rw-r--r-- | chrome_frame/chrome_frame_automation.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/chrome_frame/chrome_frame_automation.cc b/chrome_frame/chrome_frame_automation.cc index a026669..887e545 100644 --- a/chrome_frame/chrome_frame_automation.cc +++ b/chrome_frame/chrome_frame_automation.cc @@ -1168,19 +1168,20 @@ bool ChromeFrameAutomationClient::ProcessUrlRequestMessage(TabProxy* tab, // kind of beings. // By default we marshal the IPC message to the main/GUI thread and from there // we safely invoke chrome_frame_delegate_->OnMessageReceived(msg). -void ChromeFrameAutomationClient::OnMessageReceived(TabProxy* tab, +bool ChromeFrameAutomationClient::OnMessageReceived(TabProxy* tab, const IPC::Message& msg) { DCHECK(tab == tab_.get()); // Quickly process network related messages. if (url_fetcher_ && ProcessUrlRequestMessage(tab, msg, false)) - return; + return true; // Early check to avoid needless marshaling if (chrome_frame_delegate_ == NULL) - return; + return false; PostTask(FROM_HERE, NewRunnableMethod(this, &ChromeFrameAutomationClient::OnMessageReceivedUIThread, msg)); + return true; } void ChromeFrameAutomationClient::OnChannelError(TabProxy* tab) { |