From db42bd0448f01a79ddcc522be13b49651118fc82 Mon Sep 17 00:00:00 2001 From: naruse Date: Mon, 1 Aug 2011 03:10:02 +0000 Subject: [PATCH] * insns.def (concatstrings): don't use initial ASCII-8BIT string. [ruby-core:38635] [Bug #5126] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ insns.def | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 74b32a4299..9c6bea73da 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Mon Aug 1 12:00:35 2011 NARUSE, Yui + + * insns.def (concatstrings): don't use initial ASCII-8BIT string. + [ruby-core:38635] [Bug #5126] + Sun Jul 31 22:57:16 2011 Yuki Sonoda (Yugui) * enc/Makefile.in (ECHO1): Same as the recent fix in common.mk. diff --git a/insns.def b/insns.def index a300189e1d..829918c117 100644 --- a/insns.def +++ b/insns.def @@ -392,9 +392,9 @@ concatstrings (...) (VALUE val) // inc += 1 - num; { - rb_num_t i = num; + rb_num_t i = num - 1; - val = rb_str_new(0, 0); + val = rb_str_resurrect(TOPN(i)); while (i-- > 0) { const VALUE v = TOPN(i); rb_str_append(val, v);