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

Unified Diff: chrome/browser/platform_util.cc

Issue 1912303002: OpenItem now posts its task with CONTINUE_ON_SHUTDOWN semantic. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fix_delayed_analysis
Patch Set: Rebased Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/platform_util.cc
diff --git a/chrome/browser/platform_util.cc b/chrome/browser/platform_util.cc
index 5cd2e45ef73213007c86668bb94730bee4517008..c8f262fec35d0c582834e1b28e3a617467b5f8bd 100644
--- a/chrome/browser/platform_util.cc
+++ b/chrome/browser/platform_util.cc
@@ -8,6 +8,7 @@
#include "base/files/file_util.h"
#include "base/logging.h"
#include "chrome/browser/platform_util_internal.h"
+#include "chrome/common/chrome_features.h"
#include "content/public/browser/browser_thread.h"
using content::BrowserThread;
@@ -57,9 +58,14 @@ void OpenItem(Profile* profile,
OpenItemType item_type,
const OpenOperationCallback& callback) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
- BrowserThread::PostBlockingPoolTask(
+ base::SequencedWorkerPool::WorkerShutdown shutdown_mode =
+ base::FeatureList::IsEnabled(features::kBrowserHangFixesExperiment)
+ ? base::SequencedWorkerPool::CONTINUE_ON_SHUTDOWN
+ : base::SequencedWorkerPool::SKIP_ON_SHUTDOWN;
+ BrowserThread::GetBlockingPool()->PostWorkerTaskWithShutdownBehavior(
FROM_HERE, base::Bind(&VerifyAndOpenItemOnBlockingThread, full_path,
- item_type, callback));
+ item_type, callback),
+ shutdown_mode);
}
} // namespace platform_util
« 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