Launcher fails to properly quote empty command arguments
Categories
(Firefox :: Launcher Process, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox121 | --- | fixed |
People
(Reporter: saschanaz, Assigned: rkraesig)
References
Details
Attachments
(2 files)
Running firefox.exe --backgroundtask removeDirectory C:\Users\sasch\AppData\Local\Temp\firefox\xpcshellprofile "" "10", ".abc"
somehow loses the argument ""
. Running this command opens two processes with different command line arguments in serial:
"C:\Users\sasch\Documents\GitHub\gecko-dev\obj-x86_64-pc-windows-msvc\dist\bin\firefox.exe" --backgroundtask removeDirectory C:\Users\sasch\AppData\Local\Temp\firefox\xpcshellprofile "" 100 .abc
C:\Users\sasch\Documents\GitHub\gecko-dev\obj-x86_64-pc-windows-msvc\dist\bin\firefox.exe --backgroundtask removeDirectory C:\Users\sasch\AppData\Local\Temp\firefox\xpcshellprofile 100 .abc
(double spaces between the path and100
, somehow bugzilla ignores it)
This is not specific to background tasks, omitting --backgroundtask
also does the same, although in that case the first process soon disappears and the one without the quote remains.
Assignee | ||
Updated•1 year ago
|
Assignee | ||
Comment 1•1 year ago
|
||
internal::ArgStrLen
and internal::ArgToString
must behave
identically. Merge them into a common implementation function to ensure
this.
Additionally, use size_t
rather than int
as an intermediate data
type where appropriate.
No functional changes.
Updated•1 year ago
|
Assignee | ||
Comment 2•1 year ago
|
||
Quote empty arguments in command lines. Add appropriate tests.
Depends on D191127
Comment 4•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/f07dd94abdef
https://hg.mozilla.org/mozilla-central/rev/dda67fb9ec0f
Description
•