summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-04-17 02:58:37 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-04-17 02:58:37 +0000
commit26fa27fe12cab1c9af8401399dba811b6f52803b (patch)
tree461981be93d0b4c1a43375fc97a58e9024765dd9 /string.c
parent982a9d8e91a0de6abd2af3d888aba1aa2880103c (diff)
downloadruby-26fa27fe12cab1c9af8401399dba811b6f52803b.tar.gz
string.c: clear NOFREE flag at embedding
* string.c (STR_SET_EMBED): clear NOFREE flag at embedding as embedded strings no longer refer static strings. [ruby-core:68436] [Bug #10942] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50334 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r--string.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/string.c b/string.c
index 29dfdb94af..d85033ea6c 100644
--- a/string.c
+++ b/string.c
@@ -74,7 +74,7 @@ VALUE rb_cSymbol;
FL_SET((str), STR_NOEMBED);\
STR_SET_EMBED_LEN((str), 0);\
} while (0)
-#define STR_SET_EMBED(str) FL_UNSET((str), STR_NOEMBED)
+#define STR_SET_EMBED(str) FL_UNSET((str), (STR_NOEMBED|STR_NOFREE))
#define STR_SET_EMBED_LEN(str, n) do { \
long tmp_n = (n);\
RBASIC(str)->flags &= ~RSTRING_EMBED_LEN_MASK;\