summaryrefslogtreecommitdiff
path: root/ext/dl/cfunc.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-11 11:33:44 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-11 11:33:44 +0000
commit199a95775b4f0e8d7ecab2946b8d7c250a695f40 (patch)
tree623e6cac5cbf684b9066f66b4c5aae7375439f86 /ext/dl/cfunc.c
parent35b6abbca2cb419aae599d04e5855e33a97935dd (diff)
* ext/dl/cfunc.c (rb_dlcfunc_call): add taint check.
* ext/dl/dl.c (rb_dl_malloc): add rb_secure(2). * ext/dl/dl.c (rb_dl_realloc): ditto. * ext/dl/dl.c (rb_dl_free): ditto. * ext/dl/dl.c (rb_dl_ptr2value): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18496 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/cfunc.c')
-rw-r--r--ext/dl/cfunc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/dl/cfunc.c b/ext/dl/cfunc.c
index 22e8600002d..724c290f2f1 100644
--- a/ext/dl/cfunc.c
+++ b/ext/dl/cfunc.c
@@ -260,6 +260,7 @@ rb_dlcfunc_call(VALUE self, VALUE ary)
if( i >= DLSTACK_SIZE ){
rb_raise(rb_eDLError, "too many arguments (stack overflow)");
}
+ rb_check_safe_obj(RARRAY_PTR(ary)[i]);
stack[i] = NUM2LONG(RARRAY_PTR(ary)[i]);
}