X-Git-Url: https://git.reactos.org/?p=reactos.git;a=blobdiff_plain;f=reactos%2Fbase%2Fapplications%2Frapps%2Fwinmain.c;h=33e6f6f9e0a43398b9870ad80114df1ec3c2b816;hp=f39b34ab7e8c2c937373118100256c44be82c90b;hb=4956af0dbcb0f1f32c13818566cad4c3e13a6bb6;hpb=2ad9ba56bdf57b0f4f4bc1fe70779076565bd8f6 diff --git a/reactos/base/applications/rapps/winmain.c b/reactos/base/applications/rapps/winmain.c index f39b34ab7e8..33e6f6f9e0a 100644 --- a/reactos/base/applications/rapps/winmain.c +++ b/reactos/base/applications/rapps/winmain.c @@ -144,8 +144,11 @@ EnumAvailableAppProc(APPLICATION_INFO Info) PAPPLICATION_INFO ItemInfo; INT Index; - if (!IsInstalledApplication(Info.szRegName, FALSE) && - !IsInstalledApplication(Info.szRegName, TRUE)) + /* Only add a ListView entry if... + - no RegName was supplied (so we cannot determine whether the application is installed or not) or + - a RegName was supplied and the application is not installed + */ + if (!*Info.szRegName || (!IsInstalledApplication(Info.szRegName, FALSE) && !IsInstalledApplication(Info.szRegName, TRUE))) { ItemInfo = HeapAlloc(GetProcessHeap(), 0, sizeof(APPLICATION_INFO)); if (!ItemInfo) return FALSE;