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

Side by Side Diff: chrome/service/service_process.cc

Issue 8873032: Removing MessageLoop::QuitTask() from chrome/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert 3 more problematic files Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/service/service_process.h" 5 #include "chrome/service/service_process.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 // terminate. 251 // terminate.
252 if (!ForceServiceProcessShutdown("", 0)) { 252 if (!ForceServiceProcessShutdown("", 0)) {
253 Terminate(); 253 Terminate();
254 } 254 }
255 #else 255 #else
256 Terminate(); 256 Terminate();
257 #endif 257 #endif
258 } 258 }
259 259
260 void ServiceProcess::Terminate() { 260 void ServiceProcess::Terminate() {
261 main_message_loop_->PostTask(FROM_HERE, new MessageLoop::QuitTask()); 261 main_message_loop_->PostTask(FROM_HERE, MessageLoop::QuitClosure());
262 } 262 }
263 263
264 bool ServiceProcess::HandleClientDisconnect() { 264 bool ServiceProcess::HandleClientDisconnect() {
265 // If there are no enabled services or if there is an update available 265 // If there are no enabled services or if there is an update available
266 // we want to shutdown right away. Else we want to keep listening for 266 // we want to shutdown right away. Else we want to keep listening for
267 // new connections. 267 // new connections.
268 if (!enabled_services_ || update_available()) { 268 if (!enabled_services_ || update_available()) {
269 Shutdown(); 269 Shutdown();
270 return false; 270 return false;
271 } 271 }
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 } else { 361 } else {
362 Shutdown(); 362 Shutdown();
363 } 363 }
364 } 364 }
365 } 365 }
366 366
367 ServiceProcess::~ServiceProcess() { 367 ServiceProcess::~ServiceProcess() {
368 Teardown(); 368 Teardown();
369 g_service_process = NULL; 369 g_service_process = NULL;
370 } 370 }
OLDNEW
« no previous file with comments | « chrome/service/cloud_print/cloud_print_url_fetcher_unittest.cc ('k') | chrome/test/base/browser_with_test_window_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698