Commit be6e6fb2 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

user32: Initialize module handle to NULL for null driver.

parent dcae1afa
...@@ -77,7 +77,8 @@ static BOOL load_desktop_driver( HWND hwnd, HMODULE *module ) ...@@ -77,7 +77,8 @@ static BOOL load_desktop_driver( HWND hwnd, HMODULE *module )
size = sizeof(path); size = sizeof(path);
if (!RegQueryValueExW( hkey, driverW, NULL, NULL, (BYTE *)path, &size )) if (!RegQueryValueExW( hkey, driverW, NULL, NULL, (BYTE *)path, &size ))
{ {
ret = !strcmpW( path, nullW ) || (*module = LoadLibraryW( path )); if ((ret = !strcmpW( path, nullW ))) *module = NULL;
else ret = (*module = LoadLibraryW( path )) != NULL;
if (!ret) ERR( "failed to load %s\n", debugstr_w(path) ); if (!ret) ERR( "failed to load %s\n", debugstr_w(path) );
TRACE( "%s %p\n", debugstr_w(path), *module ); TRACE( "%s %p\n", debugstr_w(path), *module );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment