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

Side by Side Diff: remoting/host/it2me/it2me_native_messaging_host_main.cc

Issue 2679293002: Fix TaskScheduler initialization in remoting processes. (Closed)
Patch Set: Created 3 years, 10 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "remoting/host/it2me/it2me_native_messaging_host_main.h" 5 #include "remoting/host/it2me/it2me_native_messaging_host_main.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 new It2MeNativeMessagingHost(needs_elevation, /*policy_service=*/nullptr, 193 new It2MeNativeMessagingHost(needs_elevation, /*policy_service=*/nullptr,
194 std::move(context), std::move(factory))); 194 std::move(context), std::move(factory)));
195 195
196 host->Start(native_messaging_pipe.get()); 196 host->Start(native_messaging_pipe.get());
197 197
198 native_messaging_pipe->Start(std::move(host), std::move(channel)); 198 native_messaging_pipe->Start(std::move(host), std::move(channel));
199 199
200 // Run the loop until channel is alive. 200 // Run the loop until channel is alive.
201 run_loop.Run(); 201 run_loop.Run();
202 202
203 // Block until tasks blocking shutdown have completed their execution.
204 base::TaskScheduler::GetInstance()->Shutdown();
205
203 return kSuccessExitCode; 206 return kSuccessExitCode;
204 } 207 }
205 208
206 } // namespace remoting 209 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698