ruby-changes:13796
From: yugui <ko1@a...>
Date: Sat, 31 Oct 2009 22:16:41 +0900 (JST)
Subject: [ruby-changes:13796] Ruby:r25594 (ruby_1_9_1): merges r24828 from trunk into ruby_1_9_1.
yugui 2009-10-31 22:05:11 +0900 (Sat, 31 Oct 2009) New Revision: 25594 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=25594 Log: merges r24828 from trunk into ruby_1_9_1. -- * test/dl/test_cptr.rb (test_free=): test SEGV at first. [ruby-dev:39269] Modified files: branches/ruby_1_9_1/ChangeLog branches/ruby_1_9_1/test/dl/test_cptr.rb branches/ruby_1_9_1/version.h Index: ruby_1_9_1/ChangeLog =================================================================== --- ruby_1_9_1/ChangeLog (revision 25593) +++ ruby_1_9_1/ChangeLog (revision 25594) @@ -1,3 +1,8 @@ +Thu Sep 10 21:22:01 2009 Tanaka Akira <akr@f...> + + * test/dl/test_cptr.rb (test_free=): test SEGV at first. + [ruby-dev:39269] + Tue Mar 3 15:05:19 2009 Nobuyoshi Nakada <nobu@r...> * ext/dl/lib/dl/value.rb (DL::ValueUtil#wrap_arg): NULL for nil. Index: ruby_1_9_1/version.h =================================================================== --- ruby_1_9_1/version.h (revision 25593) +++ ruby_1_9_1/version.h (revision 25594) @@ -1,5 +1,5 @@ #define RUBY_VERSION "1.9.1" -#define RUBY_PATCHLEVEL 319 +#define RUBY_PATCHLEVEL 320 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 9 #define RUBY_VERSION_TEENY 1 Index: ruby_1_9_1/test/dl/test_cptr.rb =================================================================== --- ruby_1_9_1/test/dl/test_cptr.rb (revision 25593) +++ ruby_1_9_1/test/dl/test_cptr.rb (revision 25594) @@ -1,4 +1,5 @@ require_relative 'test_base' +require_relative '../ruby/envutil' module DL class TestCPtr < TestBase @@ -8,6 +9,20 @@ end def test_free= + assert_normal_exit(<<-"End", '[ruby-dev:39269]') + require 'dl + DL::LIBC_SO = #{LIBC_SO.dump} + DL::LIBM_SO = #{LIBM_SO.dump} + include DL + @libc = dlopen(LIBC_SO) + @libm = dlopen(LIBM_SO) + free = CFunc.new(@libc['free'], TYPE_VOID, 'free') + ptr = CPtr.malloc(4) + ptr.free = free + free.ptr + ptr.free.ptr + End + free = CFunc.new(@libc['free'], TYPE_VOID, 'free') ptr = CPtr.malloc(4) ptr.free = free -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/