summaryrefslogtreecommitdiff
path: root/re.c
diff options
context:
space:
mode:
Diffstat (limited to 're.c')
-rw-r--r--re.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/re.c b/re.c
index 4bf18f5e84..d110fe63ef 100644
--- a/re.c
+++ b/re.c
@@ -1082,8 +1082,8 @@ match_backref_number(VALUE match, VALUE backref)
return NUM2INT(backref);
case T_SYMBOL:
- name = RSTRING_PTR(rb_sym2str(backref));
- break;
+ backref = rb_sym2str(backref);
+ /* fall through */
case T_STRING:
name = StringValueCStr(backref);