Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(610)

Side by Side Diff: ipc/ipc_sync_channel.cc

Issue 2828913003: Replace "nested message loop" with "nested run loop" in comments. (Closed)
Patch Set: rebase Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/ipc_sync_channel.h ('k') | mojo/public/cpp/bindings/lib/connector.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ipc/ipc_sync_channel.h" 5 #include "ipc/ipc_sync_channel.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <utility> 10 #include <utility>
(...skipping 656 matching lines...) Expand 10 before | Expand all | Expand 10 after
667 667
668 if (dispatch) { 668 if (dispatch) {
669 // We're waiting for a reply, but we received a blocking synchronous call. 669 // We're waiting for a reply, but we received a blocking synchronous call.
670 // We must process it to avoid potential deadlocks. 670 // We must process it to avoid potential deadlocks.
671 context->GetDispatchEvent()->Reset(); 671 context->GetDispatchEvent()->Reset();
672 context->DispatchMessages(); 672 context->DispatchMessages();
673 continue; 673 continue;
674 } 674 }
675 675
676 if (should_pump_messages) 676 if (should_pump_messages)
677 WaitForReplyWithNestedMessageLoop(context); // Run a nested message loop. 677 WaitForReplyWithNestedMessageLoop(context); // Run a nested run loop.
678 678
679 break; 679 break;
680 } 680 }
681 } 681 }
682 682
683 void SyncChannel::WaitForReplyWithNestedMessageLoop(SyncContext* context) { 683 void SyncChannel::WaitForReplyWithNestedMessageLoop(SyncContext* context) {
684 base::MessageLoop::ScopedNestableTaskAllower allow( 684 base::MessageLoop::ScopedNestableTaskAllower allow(
685 base::MessageLoop::current()); 685 base::MessageLoop::current());
686 base::RunLoop nested_loop; 686 base::RunLoop nested_loop;
687 ReceivedSyncMsgQueue::NestedSendDoneWatcher watcher(context, &nested_loop); 687 ReceivedSyncMsgQueue::NestedSendDoneWatcher watcher(context, &nested_loop);
(...skipping 19 matching lines...) Expand all
707 sync_context()->GetDispatchEvent(), 707 sync_context()->GetDispatchEvent(),
708 base::Bind(&SyncChannel::OnDispatchEventSignaled, 708 base::Bind(&SyncChannel::OnDispatchEventSignaled,
709 base::Unretained(this))); 709 base::Unretained(this)));
710 } 710 }
711 711
712 void SyncChannel::OnChannelInit() { 712 void SyncChannel::OnChannelInit() {
713 pre_init_sync_message_filters_.clear(); 713 pre_init_sync_message_filters_.clear();
714 } 714 }
715 715
716 } // namespace IPC 716 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/ipc_sync_channel.h ('k') | mojo/public/cpp/bindings/lib/connector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698