1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* string.c (rb_str_replace): makes frozen shared string before

sharing.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15398 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2008-02-07 10:11:40 +00:00
parent fb506c3000
commit 1809782c3e
2 changed files with 5 additions and 2 deletions

View file

@ -1,7 +1,10 @@
Thu Feb 7 18:57:04 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
Thu Feb 7 19:11:39 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
* string.c (rb_str_dup): reverted unneeded change. [ruby-dev:33634]
* string.c (rb_str_replace): makes frozen shared string before
sharing.
Thu Feb 7 16:33:51 2008 Tanaka Akira <akr@fsij.org>
* io.c (io_reopen): don't change access mode for stdin, stdout and

View file

@ -3049,7 +3049,7 @@ rb_str_replace(VALUE str, VALUE str2)
}
else {
rb_str_modify(str);
str_replace_shared(str, str2);
str_replace_shared(str, rb_str_new4(str2));
}
OBJ_INFECT(str, str2);