* array.c (rb_ary_repeated_permutation): fix buffer size, ALLOCV_N
  already multiplies element size.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51532 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2015-08-11 05:57:11 +00:00
Родитель c7dc6a34b5
Коммит 0a8a321558
2 изменённых файлов: 6 добавлений и 1 удалений

Просмотреть файл

@ -1,3 +1,8 @@
Tue Aug 11 14:57:09 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
* array.c (rb_ary_repeated_permutation): fix buffer size, ALLOCV_N
already multiplies element size.
Tue Aug 11 12:13:20 2015 Jeremy Evans <merch-redmine@jeremyevans.net>
* test/openssl/test_ssl.rb: Fix LocalJumpErrors being raised

Просмотреть файл

@ -5179,7 +5179,7 @@ rb_ary_repeated_permutation(VALUE ary, VALUE num)
}
else { /* this is the general case */
volatile VALUE t0;
long *p = ALLOCV_N(long, t0, r * sizeof(long));
long *p = ALLOCV_N(long, t0, r);
VALUE ary0 = ary_make_shared_copy(ary); /* private defensive copy of ary */
RBASIC_CLEAR_CLASS(ary0);