mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/date/date_parse.c (date_zone_to_diff): add RB_GC_GUARD.
[ruby-dev:44337] [Bug #5152] * ext/date/data_parse.c (parse_ddd_cb): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
4d71d34855
commit
0bd01d0058
2 changed files with 11 additions and 0 deletions
|
@ -1,3 +1,10 @@
|
|||
Tue Aug 9 22:57:45 2011 CHIKANAGA Tomoyuki <nagachika00@gmail.com>
|
||||
|
||||
* ext/date/date_parse.c (date_zone_to_diff): add RB_GC_GUARD.
|
||||
[ruby-dev:44337] [Bug #5152]
|
||||
|
||||
* ext/date/data_parse.c (parse_ddd_cb): ditto.
|
||||
|
||||
Tue Aug 9 14:25:47 2011 Naohisa Goto <ngotogenome@gmail.com>
|
||||
|
||||
* ext/fiddle/conversions.c (generic_to_value): ffi_arg and ffi_sarg
|
||||
|
|
|
@ -530,6 +530,7 @@ date_zone_to_diff(VALUE str)
|
|||
}
|
||||
}
|
||||
}
|
||||
RB_GC_GUARD(str);
|
||||
ok:
|
||||
return offset;
|
||||
}
|
||||
|
@ -1322,6 +1323,7 @@ parse_ddd_cb(VALUE m, VALUE hash)
|
|||
set_hash("yday", INT2FIX(n2i(cs2, 4, 3)));
|
||||
}
|
||||
break;
|
||||
RB_GC_GUARD(s2);
|
||||
}
|
||||
if (!NIL_P(s3)) {
|
||||
cs3 = RSTRING_PTR(s3);
|
||||
|
@ -1353,6 +1355,7 @@ parse_ddd_cb(VALUE m, VALUE hash)
|
|||
break;
|
||||
}
|
||||
}
|
||||
RB_GC_GUARD(s3);
|
||||
}
|
||||
if (!NIL_P(s4)) {
|
||||
l4 = RSTRING_LEN(s4);
|
||||
|
@ -1391,6 +1394,7 @@ parse_ddd_cb(VALUE m, VALUE hash)
|
|||
*--s1 = '+';
|
||||
set_hash("offset", date_zone_to_diff(rb_str_new2(s1)));
|
||||
}
|
||||
RB_GC_GUARD(s5);
|
||||
}
|
||||
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Reference in a new issue