1
require_relative 'test_base'
2
require_relative '../ruby/envutil'
5
class TestCPtr < TestBase
12
assert_normal_exit(<<-"End", '[ruby-dev:39269]')
14
DL::LIBC_SO = #{DL::LIBC_SO.dump}
15
DL::LIBM_SO = #{DL::LIBM_SO.dump}
17
@libc = dlopen(LIBC_SO)
18
@libm = dlopen(LIBM_SO)
19
free = CFunc.new(@libc['free'], TYPE_VOID, 'free')
26
free = CFunc.new(@libc['free'], TYPE_VOID, 'free')
30
assert_equal free.ptr, ptr.free.ptr