ruby-changes:14288
From: shyouhei <ko1@a...>
Date: Wed, 16 Dec 2009 20:30:33 +0900 (JST)
Subject: [ruby-changes:14288] Ruby:r26113 (ruby_1_8_7): merge revision(s) 25656:
shyouhei 2009-12-16 20:27:51 +0900 (Wed, 16 Dec 2009) New Revision: 26113 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=26113 Log: merge revision(s) 25656: * win32/win32.c (CreateChild): allocate temporary buffer and use it instead of directly modify the passed string. [ruby-dev:39635] Modified files: branches/ruby_1_8_7/ChangeLog branches/ruby_1_8_7/version.h branches/ruby_1_8_7/win32/win32.c Index: ruby_1_8_7/ChangeLog =================================================================== --- ruby_1_8_7/ChangeLog (revision 26112) +++ ruby_1_8_7/ChangeLog (revision 26113) @@ -1,3 +1,8 @@ +Wed Dec 16 20:17:40 2009 NAKAMURA Usaku <usa@r...> + + * win32/win32.c (CreateChild): allocate temporary buffer and use it + instead of directly modify the passed string. [ruby-dev:39635] + Wed Dec 16 19:49:47 2009 URABE Shyouhei <shyouhei@r...> * instruby.rb (with_destdir): revert. [ruby-dev:39885] Index: ruby_1_8_7/version.h =================================================================== --- ruby_1_8_7/version.h (revision 26112) +++ ruby_1_8_7/version.h (revision 26113) @@ -2,7 +2,7 @@ #define RUBY_RELEASE_DATE "2009-12-16" #define RUBY_VERSION_CODE 187 #define RUBY_RELEASE_CODE 20091216 -#define RUBY_PATCHLEVEL 241 +#define RUBY_PATCHLEVEL 242 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 Index: ruby_1_8_7/win32/win32.c =================================================================== --- ruby_1_8_7/win32/win32.c (revision 26112) +++ ruby_1_8_7/win32/win32.c (revision 26113) @@ -1066,11 +1066,13 @@ } } if (p) { - shell = p; - while (*p) { - if ((unsigned char)*p == '/') - *p = '\\'; - p = CharNext(p); + char *tmp = ALLOCA_N(char, strlen(p) + 1); + strcpy(tmp, p); + shell = tmp; + while (*tmp) { + if ((unsigned char)*tmp == '/') + *tmp = '\\'; + tmp = CharNext(tmp); } } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/