diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-09-29 13:54:37 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-09-29 13:54:37 +0000 |
commit | ef08f00541f2e3f2a409b3dfc474ac8611b20452 (patch) | |
tree | a6b3f3d4c9fb4fa88c97bef565de65b4884defcd /string.c | |
parent | 2f2f92b73ed49d5de6884945d14beaee45965739 (diff) |
string.c: fix NOFREE
* string.c (str_make_independent_expand): drop NOFREE flag after
reallocation, static buffer is not pointed anymore.
[ruby-core:65317] [Bug #10304]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47737 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r-- | string.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1577,7 +1577,7 @@ str_make_independent_expand(VALUE str, long expand) memcpy(ptr, RSTRING_PTR(str), len); } STR_SET_NOEMBED(str); - FL_UNSET(str, STR_SHARED); + FL_UNSET(str, STR_SHARED|STR_NOFREE); TERM_FILL(ptr + len, termlen); RSTRING(str)->as.heap.ptr = ptr; RSTRING(str)->as.heap.len = len; |