summaryrefslogtreecommitdiffstats
path: root/ext/dl/cptr.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-12 05:15:18 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-12 05:15:18 +0000
commit12b2f196463f982408cd340b7007d1270cab5beb (patch)
treeda2604f013ff21165f240f69645e1f443c299662 /ext/dl/cptr.c
parentbd0196712c20d359e72d5b072c8c4aee98e497c4 (diff)
downloadruby-12b2f196463f982408cd340b7007d1270cab5beb.tar.gz
ruby-12b2f196463f982408cd340b7007d1270cab5beb.tar.xz
ruby-12b2f196463f982408cd340b7007d1270cab5beb.zip
* ext/dl/cptr.c (rb_dlptr_s_to_ptr): fixed shadowing variable.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@18510 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/cptr.c')
-rw-r--r--ext/dl/cptr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/dl/cptr.c b/ext/dl/cptr.c
index b5f1e239e..7487b0cf5 100644
--- a/ext/dl/cptr.c
+++ b/ext/dl/cptr.c
@@ -426,8 +426,8 @@ rb_dlptr_s_to_ptr(VALUE self, VALUE val)
ptr = rb_dlptr_new(fp, 0, NULL);
}
else if (rb_obj_is_kind_of(val, rb_cString) == Qtrue){
- char *ptr = StringValuePtr(val);
- ptr = rb_dlptr_new(ptr, RSTRING_LEN(val), NULL);
+ char *str = StringValuePtr(val);
+ ptr = rb_dlptr_new(str, RSTRING_LEN(val), NULL);
}
else if (rb_respond_to(val, id_to_ptr)){
VALUE vptr = rb_funcall(val, id_to_ptr, 0);