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

Unified Diff: chrome/browser/win/enumerate_modules_model.h

Issue 2368393004: Move EnumerateModulesModel work to the blocking pool. (Closed)
Patch Set: Address gab's comments. Created 4 years, 3 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 | chrome/browser/win/enumerate_modules_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/win/enumerate_modules_model.h
diff --git a/chrome/browser/win/enumerate_modules_model.h b/chrome/browser/win/enumerate_modules_model.h
index ce1ec23ecac2413e1c8ddcc41405c36d01892235..da0bdbd67fea8fd3df988268e479cb5e6ffdc97d 100644
--- a/chrome/browser/win/enumerate_modules_model.h
+++ b/chrome/browser/win/enumerate_modules_model.h
@@ -139,7 +139,7 @@ class ModuleEnumerator {
private:
FRIEND_TEST_ALL_PREFIXES(EnumerateModulesTest, CollapsePath);
- // This function does the actual file scanning work on the FILE thread. It
+ // This function does the actual file scanning work in the blocking pool. It
// enumerates all loaded modules in the process and other modules of interest,
// such as the registered Winsock LSP modules and stores them in
// |enumerated_modules_|. It then normalizes the module info and matches them
@@ -220,7 +220,9 @@ class ModuleEnumerator {
// ready.
//
// The member functions of this class may only be used from the UI thread. The
-// bulk of the work is actually performed on the FILE thread.
+// bulk of the work is actually performed in the blocking pool with
+// CONTINUE_ON_SHUTDOWN semantics, as the WinCrypt functions can effectively
+// block arbitrarily during shutdown.
//
// TODO(chrisha): If this logic is ever extended to other platforms, then make
// this file generic for all platforms, and remove the precompiler logic in
@@ -307,13 +309,13 @@ class EnumerateModulesModel {
void DoneScanning();
// The vector containing all the modules enumerated. Will be normalized and
- // any bad modules will be marked. Written to on the FILE thread by the
+ // any bad modules will be marked. Written to from the blocking pool by the
// |module_enumerator_|, read from on the UI thread by this class.
ModuleEnumerator::ModulesVector enumerated_modules_;
- // The object responsible for enumerating the modules on the FILE thread.
- // Only used from the UI thread. This ends up internally doing its work on the
- // FILE thread.
+ // The object responsible for enumerating the modules in the blocking pool.
+ // Only used from the UI thread. This ends up internally doing its work in the
+ // blocking pool.
std::unique_ptr<ModuleEnumerator> module_enumerator_;
// Whether the conflict notification has been acknowledged by the user. Only
« no previous file with comments | « no previous file | chrome/browser/win/enumerate_modules_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698