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

Unified Diff: chrome/browser/themes/theme_service_win.cc

Issue 1822263002: Fix DCHECK failure on bots when registry key can't be opened successfully. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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/themes/theme_service_win.cc
diff --git a/chrome/browser/themes/theme_service_win.cc b/chrome/browser/themes/theme_service_win.cc
index 6573ee805a029f94e83960f40e599815e0c02505..88a77c3c19eb78301b71a2055e40978b8ac845b1 100644
--- a/chrome/browser/themes/theme_service_win.cc
+++ b/chrome/browser/themes/theme_service_win.cc
@@ -19,7 +19,10 @@ ThemeServiceWin::ThemeServiceWin() {
if (base::win::GetVersion() >= base::win::VERSION_WIN10) {
dwm_key_.reset(new base::win::RegKey(
HKEY_CURRENT_USER, L"SOFTWARE\\Microsoft\\Windows\\DWM", KEY_READ));
- OnDwmKeyUpdated();
+ if (dwm_key_->Valid())
+ OnDwmKeyUpdated();
+ else
+ dwm_key_.reset();
}
}
« 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