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

Unified Diff: chrome/browser/process_singleton_win.cc

Issue 101004: Ensure Windows window classes are unregistered on shutdown (take 2) (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 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 | « base/message_pump_win.cc ('k') | chrome/views/widget/widget_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/process_singleton_win.cc
===================================================================
--- chrome/browser/process_singleton_win.cc (revision 14503)
+++ chrome/browser/process_singleton_win.cc (working copy)
@@ -45,8 +45,10 @@
}
ProcessSingleton::~ProcessSingleton() {
- if (window_)
+ if (window_) {
DestroyWindow(window_);
+ UnregisterClass(chrome::kMessageWindowClass, GetModuleHandle(NULL));
+ }
}
bool ProcessSingleton::NotifyOtherProcess() {
@@ -142,7 +144,8 @@
wc.lpfnWndProc = ProcessSingleton::WndProcStatic;
wc.hInstance = hinst;
wc.lpszClassName = chrome::kMessageWindowClass;
- RegisterClassEx(&wc);
+ ATOM clazz = RegisterClassEx(&wc);
+ DCHECK(clazz);
std::wstring user_data_dir;
PathService::Get(chrome::DIR_USER_DATA, &user_data_dir);
« no previous file with comments | « base/message_pump_win.cc ('k') | chrome/views/widget/widget_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698