From 0091c0ae964908f1e0227ecbcf01a7c43284136d Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Tue, 14 May 2013 11:20:49 +0200 Subject: [PATCH] riched32: Don't bother to unregister classes at process exit. --- dlls/riched32/richedit.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/dlls/riched32/richedit.c b/dlls/riched32/richedit.c index 7513273291e..44ce8434e38 100644 --- a/dlls/riched32/richedit.c +++ b/dlls/riched32/richedit.c @@ -40,16 +40,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(richedit); extern LRESULT WINAPI RichEdit10ANSIWndProc(HWND, UINT, WPARAM, LPARAM); -/* Unregisters the window class. */ -static BOOL RICHED32_Unregister(void) -{ - TRACE("\n"); - - UnregisterClassA(RICHEDIT_CLASS10A, NULL); - return TRUE; -} - - /* Registers the window class. */ static BOOL RICHED32_Register(void) { @@ -80,7 +70,9 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) return RICHED32_Register(); case DLL_PROCESS_DETACH: - return RICHED32_Unregister(); + if (lpvReserved) break; + UnregisterClassA(RICHEDIT_CLASS10A, NULL); + break; } return TRUE; }