summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--version.h2
-rw-r--r--win32/win32.c6
3 files changed, 12 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index af2e6b39e5..808e83e1f3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Thu Apr 21 01:01:28 2011 Masaya Tarui <tarui@ruby-lang.org>
+
+ * win32/win32.c (CreateChild): maximum length of lpCommandLine is
+ 32,768 characters, including the Unicode terminating null character.
+
Sat Oct 9 16:54:28 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* configure.in (RSHIFT): quote to get rid of argument expansion
diff --git a/version.h b/version.h
index f9095bd22d..b04bd5e4ff 100644
--- a/version.h
+++ b/version.h
@@ -1,5 +1,5 @@
#define RUBY_VERSION "1.9.2"
-#define RUBY_PATCHLEVEL 235
+#define RUBY_PATCHLEVEL 236
#define RUBY_VERSION_MAJOR 1
#define RUBY_VERSION_MINOR 9
#define RUBY_VERSION_TEENY 1
diff --git a/win32/win32.c b/win32/win32.c
index 317792a572..b1984f57fd 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -1040,6 +1040,12 @@ CreateChild(const char *cmd, const char *prog, SECURITY_ATTRIBUTES *psa,
dwCreationFlags = (NORMAL_PRIORITY_CLASS);
+ if (lstrlenW(cmd) > 32767) {
+ child->pid = 0; /* release the slot */
+ errno = E2BIG;
+ return NULL;
+ }
+
RUBY_CRITICAL({
fRet = CreateProcess(prog, (char *)cmd, psa, psa,
psa->bInheritHandle, dwCreationFlags, NULL, NULL,