Skip to content

Commit 3e36557

Browse files
jason-simmonsCommit Queue
authored andcommitted
[VM/dartdev] Escape VM options when running dartdev on Windows
VM options may include flags like --packages that include file paths. TEST=ci Bug: flutter/flutter#173716 Change-Id: I0d88f5383a7d2daf27568ccfb5c8f447965592cd Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/445113 Commit-Queue: Jason Simmons <[email protected]> Reviewed-by: Ben Konyi <[email protected]>
1 parent ae835a6 commit 3e36557

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

runtime/bin/dartdev.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,11 @@ class DartDev {
658658
// Copy in VM options if any.
659659
// Copy in any vm options that need to be passed to the execed process.
660660
for (intptr_t i = 0; i < num_vm_options; ++i) {
661+
#if defined(DART_HOST_OS_WINDOWS)
662+
argv_[i + idx] = StringUtilsWin::ArgumentEscape(vm_options[i]);
663+
#else
661664
argv_[i + idx] = Utils::StrDup(vm_options[i]);
665+
#endif
662666
}
663667
idx += num_vm_options;
664668
{

0 commit comments

Comments
 (0)