Don't crash if NULL is passed as the class list to OpenThemeData().

This commit is contained in:
Frank Richter 2005-07-12 16:59:20 +00:00 committed by Alexandre Julliard
parent 6aa0cc5e3c
commit 0bd04866e8
1 changed files with 2 additions and 0 deletions

View File

@ -330,6 +330,8 @@ HTHEME WINAPI OpenThemeData(HWND hwnd, LPCWSTR pszClassList)
if(!pszUseClassList)
pszUseClassList = pszClassList;
if (!pszClassList) return NULL;
hTheme = MSSTYLES_OpenThemeClass(pszAppName, pszUseClassList);
if(IsWindow(hwnd))
SetPropW(hwnd, MAKEINTATOMW(atWindowTheme), hTheme);