diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-03-14 00:10:49 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-03-14 00:10:49 +0000 |
commit | bce7601f73fa72465b65c3dacaddc21ac904ac92 (patch) | |
tree | bd8d55b839882ed64955602d55ad219c10353113 | |
parent | f963fa6956c915e267546a177aea89a748592370 (diff) | |
download | ruby-bce7601f73fa72465b65c3dacaddc21ac904ac92.tar.gz |
* string.c (rb_str_subpat_set): must make str independent after
rb_reg_search() matched.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2197 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | string.c | 1 |
2 files changed, 6 insertions, 0 deletions
@@ -2,6 +2,11 @@ Thu Mar 14 08:57:41 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp> * dir.c (rb_push_glob): avoid SEGV when a block given. +Thu Mar 14 00:16:02 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp> + + * string.c (rb_str_subpat_set): must make str independent after + rb_reg_search() matched. + Wed Mar 13 19:05:15 2002 Akinori MUSHA <knu@iDaemons.org> * dir.c: FNM_PERIOD is obsoleted and FNM_DOTMATCH is introduced @@ -1252,6 +1252,7 @@ rb_str_subpat_set(str, re, nth, val) } end = RMATCH(match)->END(nth); len = end - start; + rb_str_modify(str); rb_str_update(str, start, len, val); } |