Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1432)

Unified Diff: runtime/bin/process_patch.dart

Issue 15782003: Use correct path escape on Windows, for Process. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/standalone/io/process_shell_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/process_patch.dart
diff --git a/runtime/bin/process_patch.dart b/runtime/bin/process_patch.dart
index b957bacb4c6cbd5909c5f9b554edf33b27da692a..729a7b5f492df88269d41130423090dab933aac2 100644
--- a/runtime/bin/process_patch.dart
+++ b/runtime/bin/process_patch.dart
@@ -140,7 +140,6 @@ class _ProcessImpl extends NativeFieldWrapperClass1 implements Process {
shellArguments.add('/c');
shellArguments.add(executable);
for (var arg in arguments) {
- arg = arg.replaceAll('"', r'\"');
shellArguments.add(arg);
}
} else {
@@ -159,7 +158,9 @@ class _ProcessImpl extends NativeFieldWrapperClass1 implements Process {
String _windowsArgumentEscape(String argument) {
var result = argument;
- if (argument.contains('\t') || argument.contains(' ')) {
+ if (argument.contains('\t') ||
+ argument.contains(' ') ||
+ argument.contains('"')) {
// Produce something that the C runtime on Windows will parse
// back as this string.
« no previous file with comments | « no previous file | tests/standalone/io/process_shell_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698