mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* string.c (rb_str_clear): avoid revealing NULL pointer.
[ruby-dev:24766] * string.c (str_gsub): add paranoid check. [ruby-dev:24827] * string.c (str_mod_check): check frozen status as well. [ruby-dev:24801] * lib/mathn.rb (Integer::gcd2): faster implementation by <erlercw@siu.edu>. [ruby-talk:120232] * ext/gdbm/gdbm.c (fgdbm_store): StringValue() may alter string pointer. [ruby-dev:24783] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
8f1c92af4f
commit
0f36ecebe0
8 changed files with 82 additions and 47 deletions
|
@ -445,11 +445,11 @@ fsdbm_store(obj, keystr, valstr)
|
|||
|
||||
fdbm_modify(obj);
|
||||
StringValue(keystr);
|
||||
StringValue(valstr);
|
||||
|
||||
key.dptr = RSTRING(keystr)->ptr;
|
||||
key.dsize = RSTRING(keystr)->len;
|
||||
|
||||
StringValue(valstr);
|
||||
val.dptr = RSTRING(valstr)->ptr;
|
||||
val.dsize = RSTRING(valstr)->len;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue