mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
merge revision(s) 57634: [Backport #13150]
marshal.c: revert r57631 partially * marshal.c (rb_marshal_dump_limited): do not free dump_arg, which may be dereferenced in check_dump_arg due to continuation, and get rid of dangling pointers. * marshal.c (rb_marshal_load_with_proc): ditto for load_arg. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_3@59551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
8bf48ec307
commit
ecc889b1c8
3 changed files with 13 additions and 5 deletions
|
@ -1,3 +1,11 @@
|
|||
Wed Aug 9 21:16:22 2017 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* marshal.c (rb_marshal_dump_limited): do not free dump_arg, which
|
||||
may be dereferenced in check_dump_arg due to continuation, and
|
||||
get rid of dangling pointers.
|
||||
|
||||
* marshal.c (rb_marshal_load_with_proc): ditto for load_arg.
|
||||
|
||||
Wed Aug 9 21:13:24 2017 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* compile.c (iseq_compile_each): remove unused definition of unused
|
||||
|
|
|
@ -1051,8 +1051,8 @@ rb_marshal_dump_limited(VALUE obj, VALUE port, int limit)
|
|||
rb_io_write(arg->dest, arg->str);
|
||||
rb_str_resize(arg->str, 0);
|
||||
}
|
||||
free_dump_arg(arg);
|
||||
rb_gc_force_recycle(wrapper);
|
||||
clear_dump_arg(arg);
|
||||
RB_GC_GUARD(wrapper);
|
||||
|
||||
return port;
|
||||
}
|
||||
|
@ -2090,8 +2090,8 @@ rb_marshal_load_with_proc(VALUE port, VALUE proc)
|
|||
|
||||
if (!NIL_P(proc)) arg->proc = proc;
|
||||
v = r_object(arg);
|
||||
free_load_arg(arg);
|
||||
rb_gc_force_recycle(wrapper);
|
||||
clear_load_arg(arg);
|
||||
RB_GC_GUARD(wrapper);
|
||||
|
||||
return v;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#define RUBY_VERSION "2.3.5"
|
||||
#define RUBY_RELEASE_DATE "2017-08-09"
|
||||
#define RUBY_PATCHLEVEL 360
|
||||
#define RUBY_PATCHLEVEL 361
|
||||
|
||||
#define RUBY_RELEASE_YEAR 2017
|
||||
#define RUBY_RELEASE_MONTH 8
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue