summaryrefslogtreecommitdiff
path: root/struct.c
diff options
context:
space:
mode:
Diffstat (limited to 'struct.c')
-rw-r--r--struct.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/struct.c b/struct.c
index 9de9915493..82b69964a8 100644
--- a/struct.c
+++ b/struct.c
@@ -157,7 +157,7 @@ make_struct(name, member, klass)
nstr = rb_class_new(klass);
}
else {
- char *cname = STR2CSTR(name);
+ char *cname = StringValuePtr(name);
id = rb_intern(cname);
if (!rb_is_const_id(id)) {
rb_raise(rb_eNameError, "identifier %s needs to be constant", cname);