[前][次][番号順一覧][スレッド一覧]

ruby-changes:26422

From: ngoto <ko1@a...>
Date: Wed, 19 Dec 2012 23:47:36 +0900 (JST)
Subject: [ruby-changes:26422] ngoto:r38473 (trunk): * marshal.c (marshal_dump, marshal_load): fix SEGV during make rdoc

ngoto	2012-12-19 23:47:26 +0900 (Wed, 19 Dec 2012)

  New Revision: 38473

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=38473

  Log:
    * marshal.c (marshal_dump, marshal_load): fix SEGV during make rdoc
      and test failure in TestMarshal#test_gc and test_context_switch
      on SPARC Solaris 10 compiled with Oracle Solaris Studio 12.3.
      [Bug #7591] [ruby-dev:46772]

  Modified files:
    trunk/ChangeLog
    trunk/marshal.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 38472)
+++ ChangeLog	(revision 38473)
@@ -1,3 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Dec 19 23:36:12 2012  Naohisa Goto  <ngotogenome@g...>
+
+	* marshal.c (marshal_dump, marshal_load): fix SEGV during make rdoc
+	  and test failure in TestMarshal#test_gc and test_context_switch
+	  on SPARC Solaris 10 compiled with Oracle Solaris Studio 12.3.
+	  [Bug #7591] [ruby-dev:46772]
+
 Wed Dec 19 19:34:03 2012  Nobuyoshi Nakada  <nobu@r...>
 
 	* object.c (rb_mod_const_get): nul byte is invalid as constant name.
Index: marshal.c
===================================================================
--- marshal.c	(revision 38472)
+++ marshal.c	(revision 38473)
@@ -934,7 +934,7 @@ marshal_dump(int argc, VALUE *argv) https://github.com/ruby/ruby/blob/trunk/marshal.c#L934
 	else if (NIL_P(a1)) io_needed();
 	else port = a1;
     }
-    wrapper = TypedData_Make_Struct(rb_cData, struct dump_arg, &dump_arg_data, arg);
+    RB_GC_GUARD(wrapper) = TypedData_Make_Struct(rb_cData, struct dump_arg, &dump_arg_data, arg);
     arg->dest = 0;
     arg->symbols = st_init_numtable();
     arg->data    = st_init_numtable();
@@ -1907,7 +1907,7 @@ marshal_load(int argc, VALUE *argv) https://github.com/ruby/ruby/blob/trunk/marshal.c#L1907
     else {
 	io_needed();
     }
-    wrapper = TypedData_Make_Struct(rb_cData, struct load_arg, &load_arg_data, arg);
+    RB_GC_GUARD(wrapper) = TypedData_Make_Struct(rb_cData, struct load_arg, &load_arg_data, arg);
     arg->infection = infection;
     arg->src = port;
     arg->offset = 0;

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]