summaryrefslogtreecommitdiff
path: root/ext/dl/cfunc.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-06-04 01:46:36 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-06-04 01:46:36 +0000
commitda0ac85107ef9f26b68f0480b7c08893611d2be4 (patch)
treee9e9229db7c3e4c144bf73d90623fdfa8ff8e81f /ext/dl/cfunc.c
parentbc561d0b93f3f73b0e55a153e05b6543f193a344 (diff)
* ext/dl/cfunc.c (rb_dlcfunc_inspect): should taint the result.
[ruby-dev:41533] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/cfunc.c')
-rw-r--r--ext/dl/cfunc.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/dl/cfunc.c b/ext/dl/cfunc.c
index 38ff2cb8b1e..536a7231a83 100644
--- a/ext/dl/cfunc.c
+++ b/ext/dl/cfunc.c
@@ -284,15 +284,18 @@ rb_dlcfunc_set_ptr(VALUE self, VALUE addr)
static VALUE
rb_dlcfunc_inspect(VALUE self)
{
+ VALUE val;
struct cfunc_data *cfunc;
TypedData_Get_Struct(self, struct cfunc_data, &dlcfunc_data_type, cfunc);
- return rb_sprintf("#<DL::CFunc:%p ptr=%p type=%d name='%s'>",
+ val = rb_sprintf("#<DL::CFunc:%p ptr=%p type=%d name='%s'>",
cfunc,
cfunc->ptr,
cfunc->type,
cfunc->name ? cfunc->name : "");
+ OBJ_TAINT(val);
+ return val;
}