Index: content/browser/browser_main_loop.cc |
=================================================================== |
--- content/browser/browser_main_loop.cc (revision 116282) |
+++ content/browser/browser_main_loop.cc (working copy) |
@@ -497,6 +497,14 @@ |
parts_->PostStopThread(id); |
} |
+ // Close the blocking I/O pool after the other threads. Other threads such |
+ // as the I/O thread may need to schedule work like closing files or flushing |
+ // data during shutdown, so the blocking pool needs to be available. There |
+ // may also be slow operations pending that will blcok shutdown, so closing |
+ // it here (which will block until required operations are complete) gives |
+ // more head start for those operations to finish. |
+ BrowserThreadImpl::ShutdownThreadPool(); |
+ |
if (parts_.get()) |
parts_->PostDestroyThreads(); |
} |