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

Side by Side Diff: content/child/child_thread.cc

Issue 270633009: [FileAPI] Clean up WebFileSystemImpl before Blink shutdown (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: move to ChildThread Created 6 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 | « no previous file | no next file » | 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 "content/child/child_thread.h" 5 #include "content/child/child_thread.h"
6 6
7 #include <signal.h> 7 #include <signal.h>
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 11 matching lines...) Expand all
22 #include "base/synchronization/condition_variable.h" 22 #include "base/synchronization/condition_variable.h"
23 #include "base/synchronization/lock.h" 23 #include "base/synchronization/lock.h"
24 #include "base/threading/thread_local.h" 24 #include "base/threading/thread_local.h"
25 #include "base/tracked_objects.h" 25 #include "base/tracked_objects.h"
26 #include "components/tracing/child_trace_message_filter.h" 26 #include "components/tracing/child_trace_message_filter.h"
27 #include "content/child/child_histogram_message_filter.h" 27 #include "content/child/child_histogram_message_filter.h"
28 #include "content/child/child_process.h" 28 #include "content/child/child_process.h"
29 #include "content/child/child_resource_message_filter.h" 29 #include "content/child/child_resource_message_filter.h"
30 #include "content/child/child_shared_bitmap_manager.h" 30 #include "content/child/child_shared_bitmap_manager.h"
31 #include "content/child/fileapi/file_system_dispatcher.h" 31 #include "content/child/fileapi/file_system_dispatcher.h"
32 #include "content/child/fileapi/webfilesystem_impl.h"
32 #include "content/child/mojo/mojo_application.h" 33 #include "content/child/mojo/mojo_application.h"
33 #include "content/child/power_monitor_broadcast_source.h" 34 #include "content/child/power_monitor_broadcast_source.h"
34 #include "content/child/quota_dispatcher.h" 35 #include "content/child/quota_dispatcher.h"
35 #include "content/child/quota_message_filter.h" 36 #include "content/child/quota_message_filter.h"
36 #include "content/child/resource_dispatcher.h" 37 #include "content/child/resource_dispatcher.h"
37 #include "content/child/service_worker/service_worker_dispatcher.h" 38 #include "content/child/service_worker/service_worker_dispatcher.h"
38 #include "content/child/service_worker/service_worker_message_filter.h" 39 #include "content/child/service_worker/service_worker_message_filter.h"
39 #include "content/child/socket_stream_dispatcher.h" 40 #include "content/child/socket_stream_dispatcher.h"
40 #include "content/child/thread_safe_sender.h" 41 #include "content/child/thread_safe_sender.h"
41 #include "content/child/websocket_dispatcher.h" 42 #include "content/child/websocket_dispatcher.h"
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
333 // but it wasn't possible to do so on POSIX. 334 // but it wasn't possible to do so on POSIX.
334 channel_->ClearIPCTaskRunner(); 335 channel_->ClearIPCTaskRunner();
335 g_lazy_tls.Pointer()->Set(NULL); 336 g_lazy_tls.Pointer()->Set(NULL);
336 } 337 }
337 338
338 void ChildThread::Shutdown() { 339 void ChildThread::Shutdown() {
339 // Delete objects that hold references to blink so derived classes can 340 // Delete objects that hold references to blink so derived classes can
340 // safely shutdown blink in their Shutdown implementation. 341 // safely shutdown blink in their Shutdown implementation.
341 file_system_dispatcher_.reset(); 342 file_system_dispatcher_.reset();
342 quota_dispatcher_.reset(); 343 quota_dispatcher_.reset();
344 WebFileSystemImpl::DeleteThreadSpecificInstance();
343 } 345 }
344 346
345 void ChildThread::OnChannelConnected(int32 peer_pid) { 347 void ChildThread::OnChannelConnected(int32 peer_pid) {
346 channel_connected_factory_.InvalidateWeakPtrs(); 348 channel_connected_factory_.InvalidateWeakPtrs();
347 } 349 }
348 350
349 void ChildThread::OnChannelError() { 351 void ChildThread::OnChannelError() {
350 set_on_channel_error_called(true); 352 set_on_channel_error_called(true);
351 base::MessageLoop::current()->Quit(); 353 base::MessageLoop::current()->Quit();
352 } 354 }
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
540 // inflight that would addref it. 542 // inflight that would addref it.
541 Send(new ChildProcessHostMsg_ShutdownRequest); 543 Send(new ChildProcessHostMsg_ShutdownRequest);
542 } 544 }
543 545
544 void ChildThread::EnsureConnected() { 546 void ChildThread::EnsureConnected() {
545 VLOG(0) << "ChildThread::EnsureConnected()"; 547 VLOG(0) << "ChildThread::EnsureConnected()";
546 base::KillProcess(base::GetCurrentProcessHandle(), 0, false); 548 base::KillProcess(base::GetCurrentProcessHandle(), 0, false);
547 } 549 }
548 550
549 } // namespace content 551 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698