mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[RAPPS] Fix command line handling
This commit is contained in:
parent
4f8dc9c266
commit
f133d01f20
3 changed files with 7 additions and 7 deletions
|
@ -402,7 +402,7 @@ CAvailableApplicationInfo* CAvailableApps::FindInfo(const ATL::CStringW& szAppNa
|
|||
while (CurrentListPosition != NULL)
|
||||
{
|
||||
info = m_InfoList.GetNext(CurrentListPosition);
|
||||
if (info->m_szName == szAppName)
|
||||
if (info->m_szName.CompareNoCase(szAppName) == 0)
|
||||
{
|
||||
return info;
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
#include <setupapi.h>
|
||||
|
||||
#define MIN_ARGS 2
|
||||
#define MIN_ARGS 3
|
||||
|
||||
BOOL UseCmdParameters(LPWSTR lpCmdLine)
|
||||
{
|
||||
|
@ -25,17 +25,17 @@ BOOL UseCmdParameters(LPWSTR lpCmdLine)
|
|||
|
||||
// TODO: use DB filenames as names because they're shorter
|
||||
ATL::CSimpleArray<ATL::CStringW> arrNames;
|
||||
if (!StrCmpW(argv[0], CMD_KEY_INSTALL))
|
||||
if (!StrCmpIW(argv[1], CMD_KEY_INSTALL))
|
||||
{
|
||||
for (INT i = 1; i < argc; ++i)
|
||||
for (INT i = 2; i < argc; ++i)
|
||||
{
|
||||
arrNames.Add(argv[i]);
|
||||
}
|
||||
}
|
||||
else
|
||||
if (!StrCmpW(argv[0], CMD_KEY_SETUP))
|
||||
if (!StrCmpIW(argv[1], CMD_KEY_SETUP))
|
||||
{
|
||||
HINF InfHandle = SetupOpenInfFileW(argv[1], NULL, INF_STYLE_WIN4, NULL);
|
||||
HINF InfHandle = SetupOpenInfFileW(argv[2], NULL, INF_STYLE_WIN4, NULL);
|
||||
if (InfHandle == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
return FALSE;
|
||||
|
|
|
@ -160,7 +160,7 @@ INT WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLi
|
|||
InitCommonControls();
|
||||
|
||||
// skip window creation if there were some keys
|
||||
if (!UseCmdParameters(lpCmdLine))
|
||||
if (!UseCmdParameters(GetCommandLineW()))
|
||||
{
|
||||
if (SettingsInfo.bUpdateAtStart || bIsFirstLaunch)
|
||||
CAvailableApps::ForceUpdateAppsDB();
|
||||
|
|
Loading…
Reference in a new issue