Quote empty arguments in Windows command line generation

This commit is contained in:
Andrea Mazzoleni 2026-08-18 10:30:34 +02:00
parent 7ab8aa69c4
commit 3c88559379
2 changed files with 6 additions and 0 deletions

View file

@ -42,6 +42,9 @@ static int build_spindown_argv(int argc, char* argv[], char* spindown_argv[5])
static int needs_quote(const WCHAR* arg)
{
if (*arg == 0)
return 1;
while (*arg) {
if (*arg == L' ' || *arg == L'\t' || *arg == L'"')
return 1;

View file

@ -2493,6 +2493,9 @@ int windows_join(thread_id_t thread, void** retval)
static int needs_quote(const WCHAR* arg)
{
if (*arg == 0)
return 1;
while (*arg) {
if (*arg == L' ' || *arg == L'\t' || *arg == L'"')
return 1;