diff --git a/programs/explorer/desktop.c b/programs/explorer/desktop.c index f525c23d819..94d178880a8 100644 --- a/programs/explorer/desktop.c +++ b/programs/explorer/desktop.c @@ -857,11 +857,7 @@ static HMODULE load_graphics_driver( const WCHAR *driver, const GUID *guid ) name = next; } - if (module) - { - GetModuleFileNameW( module, buffer, MAX_PATH ); - TRACE( "display %s driver %s\n", debugstr_guid(guid), debugstr_w(buffer) ); - } + TRACE( "display %s driver %s\n", debugstr_guid(guid), debugstr_w(libname) ); swprintf( key, ARRAY_SIZE(key), device_keyW, guid->Data1, guid->Data2, guid->Data3, guid->Data4[0], guid->Data4[1], guid->Data4[2], guid->Data4[3], @@ -872,7 +868,7 @@ static HMODULE load_graphics_driver( const WCHAR *driver, const GUID *guid ) { if (module || null_driver) RegSetValueExW( hkey, graphics_driverW, 0, REG_SZ, - (BYTE *)buffer, (lstrlenW(buffer) + 1) * sizeof(WCHAR) ); + (BYTE *)libname, (lstrlenW(libname) + 1) * sizeof(WCHAR) ); else RegSetValueExA( hkey, "DriverError", 0, REG_SZ, (BYTE *)error, strlen(error) + 1 ); RegCloseKey( hkey );