reg: Abort 'query' operation when parsing command-line arguments that are not switches.
Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
51e83dec29
commit
2c7d74594f
|
@ -334,9 +334,12 @@ int reg_query(int argc, WCHAR *argvW[])
|
||||||
|
|
||||||
for (i = 3; i < argc; i++)
|
for (i = 3; i < argc; i++)
|
||||||
{
|
{
|
||||||
if (argvW[i][0] == '/' || argvW[i][0] == '-')
|
WCHAR *str;
|
||||||
{
|
|
||||||
WCHAR *str = &argvW[i][1];
|
if (argvW[i][0] != '/' && argvW[i][0] != '-')
|
||||||
|
goto invalid;
|
||||||
|
|
||||||
|
str = &argvW[i][1];
|
||||||
|
|
||||||
if (!lstrcmpiW(str, L"ve"))
|
if (!lstrcmpiW(str, L"ve"))
|
||||||
{
|
{
|
||||||
|
@ -361,7 +364,6 @@ int reg_query(int argc, WCHAR *argvW[])
|
||||||
goto invalid;
|
goto invalid;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (value_name && value_empty)
|
if (value_name && value_empty)
|
||||||
goto invalid;
|
goto invalid;
|
||||||
|
|
Loading…
Reference in New Issue