[前][次][番号順一覧][スレッド一覧]

ruby-changes:35249

From: usa <ko1@a...>
Date: Sun, 31 Aug 2014 15:30:57 +0900 (JST)
Subject: [ruby-changes:35249] usa:r47331 (ruby_2_0_0): merge revision(s) 46416: [Backport #9942]

usa	2014-08-31 15:30:50 +0900 (Sun, 31 Aug 2014)

  New Revision: 47331

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=47331

  Log:
    merge revision(s) 46416: [Backport #9942]
    
    * array.c (rb_ary_permutation): `p` is the array of size `r`, as
      commented at permute0().  since `n >= r` here, buffer overflow
      never happened, just reduce unnecessary allocation though.

  Modified directories:
    branches/ruby_2_0_0/
  Modified files:
    branches/ruby_2_0_0/ChangeLog
    branches/ruby_2_0_0/array.c
    branches/ruby_2_0_0/version.h
Index: ruby_2_0_0/array.c
===================================================================
--- ruby_2_0_0/array.c	(revision 47330)
+++ ruby_2_0_0/array.c	(revision 47331)
@@ -4660,7 +4660,7 @@ rb_ary_permutation(int argc, VALUE *argv https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/array.c#L4660
 	}
     }
     else {             /* this is the general case */
-	volatile VALUE t0 = tmpbuf(n,sizeof(long));
+	volatile VALUE t0 = tmpbuf(r,sizeof(long));
 	long *p = (long*)RSTRING_PTR(t0);
 	volatile VALUE t1 = tmpbuf(n,sizeof(char));
 	char *used = (char*)RSTRING_PTR(t1);
Index: ruby_2_0_0/ChangeLog
===================================================================
--- ruby_2_0_0/ChangeLog	(revision 47330)
+++ ruby_2_0_0/ChangeLog	(revision 47331)
@@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/ChangeLog#L1
+Sun Aug 31 15:23:25 2014  Nobuyoshi Nakada  <nobu@r...>
+
+	* array.c (rb_ary_permutation): `p` is the array of size `r`, as
+	  commented at permute0().  since `n >= r` here, buffer overflow
+	  never happened, just reduce unnecessary allocation though.
+
 Mon Jul  7 13:05:04 2014  SHIBATA Hiroshi  <shibata.hiroshi@g...>
 
 	* test/test_timeout.rb (test_timeout): inverted test condition.
Index: ruby_2_0_0/version.h
===================================================================
--- ruby_2_0_0/version.h	(revision 47330)
+++ ruby_2_0_0/version.h	(revision 47331)
@@ -1,10 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_0_0/version.h#L1
 #define RUBY_VERSION "2.0.0"
-#define RUBY_RELEASE_DATE "2014-07-07"
-#define RUBY_PATCHLEVEL 531
+#define RUBY_RELEASE_DATE "2014-08-31"
+#define RUBY_PATCHLEVEL 532
 
 #define RUBY_RELEASE_YEAR 2014
-#define RUBY_RELEASE_MONTH 7
-#define RUBY_RELEASE_DAY 7
+#define RUBY_RELEASE_MONTH 8
+#define RUBY_RELEASE_DAY 31
 
 #include "ruby/version.h"
 

Property changes on: ruby_2_0_0
___________________________________________________________________
Modified: svn:mergeinfo
   Merged /trunk:r46416


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]