ruby-changes:7990
From: usa <ko1@a...>
Date: Wed, 24 Sep 2008 14:40:43 +0900 (JST)
Subject: [ruby-changes:7990] Ruby:r19514 (ruby_1_8): * lib/tmpdir.rb: setup buffer with nul characters instead of spaces.
usa 2008-09-24 14:40:34 +0900 (Wed, 24 Sep 2008) New Revision: 19514 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=19514 Log: * lib/tmpdir.rb: setup buffer with nul characters instead of spaces. fixed [ruby-dev:36493] Modified files: branches/ruby_1_8/ChangeLog branches/ruby_1_8/lib/tmpdir.rb Index: ruby_1_8/ChangeLog =================================================================== --- ruby_1_8/ChangeLog (revision 19513) +++ ruby_1_8/ChangeLog (revision 19514) @@ -1,3 +1,8 @@ +Wed Sep 24 14:40:21 2008 NAKAMURA Usaku <usa@r...> + + * lib/tmpdir.rb: setup buffer with nul characters instead of spaces. + fixed [ruby-dev:36493] + Wed Sep 24 14:11:59 2008 Yukihiro Matsumoto <matz@r...> * lib/rexml/formatters/pretty.rb (REXML::Formatters::Pretty#wrap): Index: ruby_1_8/lib/tmpdir.rb =================================================================== --- ruby_1_8/lib/tmpdir.rb (revision 19513) +++ ruby_1_8/lib/tmpdir.rb (revision 19514) @@ -14,7 +14,7 @@ require 'Win32API' CSIDL_LOCAL_APPDATA = 0x001c max_pathlen = 260 - windir = ' '*(max_pathlen+1) + windir = "\0"*(max_pathlen+1) begin getdir = Win32API.new('shell32', 'SHGetFolderPath', 'LLLLP', 'L') raise RuntimeError if getdir.call(0, CSIDL_LOCAL_APPDATA, 0, 0, windir) != 0 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/