summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2012-05-09 03:40:26 +0200
committerBruno Haible <bruno@clisp.org>2012-05-09 03:40:26 +0200
commitaa3de1af836fb58f4d28214154afc804e85e49f9 (patch)
tree6e1dde55ba74ddf6d6f8878d6e698fcee1a715f9
parent9b3cba021116a2c273ba15564dbcd6fe5dc6ad2a (diff)
downloadgnulib-aa3de1af836fb58f4d28214154afc804e85e49f9.tar.gz
execute, spawn-pipe: Escape '*' characters in arguments on Windows.
* lib/w32spawn.h (SHELL_SPECIAL_CHARS): Add the '*' character.
-rw-r--r--ChangeLog5
-rw-r--r--lib/w32spawn.h4
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index d329c3a13f..ba38632bc3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2012-05-08 Bruno Haible <bruno@clisp.org>
+ execute, spawn-pipe: Escape '*' characters in arguments on Windows.
+ * lib/w32spawn.h (SHELL_SPECIAL_CHARS): Add the '*' character.
+
+2012-05-08 Bruno Haible <bruno@clisp.org>
+
Tests for module 'system-quote'.
* modules/system-quote-tests: New file.
* tests/test-system-quote.sh: New file.
diff --git a/lib/w32spawn.h b/lib/w32spawn.h
index 4cdb843442..bbc7a3d4d4 100644
--- a/lib/w32spawn.h
+++ b/lib/w32spawn.h
@@ -115,8 +115,10 @@ undup_safer_noinherit (int tempfd, int origfd)
\" -> "
\\\" -> \"
\\\\\" -> \\"
+ - '*' characters may get expanded or lead to a failure with error code
+ ERROR_PATH_NOT_FOUND.
*/
-#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
+#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037*"
#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
static char **
prepare_spawn (char **argv)