summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authordavygrvy <davygrvy@pobox.com>2004-02-02 02:36:14 (GMT)
committerdavygrvy <davygrvy@pobox.com>2004-02-02 02:36:14 (GMT)
commit90df62b250b6b243f717cedebfd659b964a94714 (patch)
tree5427e8ad1da0106d4f6bc086c61bd4e0e8c11b08 /win
parenta4410d44c599b0e3d8d1bf561ace6fa1fcb65c5b (diff)
downloadtcl-90df62b250b6b243f717cedebfd659b964a94714.zip
tcl-90df62b250b6b243f717cedebfd659b964a94714.tar.gz
tcl-90df62b250b6b243f717cedebfd659b964a94714.tar.bz2
* tests/winPipe.test: Six more cases added.
* win/tclWinPipe.c: Fixed BuildCommandLine() to pass the new cases.
Diffstat (limited to 'win')
-rw-r--r--win/tclWinPipe.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/win/tclWinPipe.c b/win/tclWinPipe.c
index 4d3a7ac..469952e 100644
--- a/win/tclWinPipe.c
+++ b/win/tclWinPipe.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclWinPipe.c,v 1.42 2004/02/02 01:13:10 davygrvy Exp $
+ * RCS: @(#) $Id: tclWinPipe.c,v 1.43 2004/02/02 02:36:15 davygrvy Exp $
*/
#include "tclWinInt.h"
@@ -1609,7 +1609,7 @@ BuildCommandLine(
start = special;
while (1) {
special++;
- if (*special == '"') {
+ if (*special == '"' || (quote && *special == '\0')) {
/*
* N backslashes followed a quote -> insert
* N * 2 + 1 backslashes then a quote.
@@ -1623,10 +1623,6 @@ BuildCommandLine(
break;
}
}
- /*
- * Do it twice when arg is quoted.
- */
- if (quote) Tcl_DStringAppend(&ds, start, (int) (special - start));
Tcl_DStringAppend(&ds, start, (int) (special - start));
start = special;
}