diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-11-14 15:41:40 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-11-14 15:41:40 +0000 |
commit | 7a084356a8aa424336f4638a0d2878473041e743 (patch) | |
tree | b4be2daabe661ccbee038408fe0a4a4be85e9699 /ext/sdbm | |
parent | 6a3d357ceae266a96599a4bf2454731d774cb61d (diff) | |
download | ruby-7a084356a8aa424336f4638a0d2878473041e743.tar.gz ruby-7a084356a8aa424336f4638a0d2878473041e743.tar.xz ruby-7a084356a8aa424336f4638a0d2878473041e743.zip |
* 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: http://svn.ruby-lang.org/repos/ruby/trunk@7265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/sdbm')
-rw-r--r-- | ext/sdbm/init.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/sdbm/init.c b/ext/sdbm/init.c index eec9e71a3..104faa0e4 100644 --- a/ext/sdbm/init.c +++ b/ext/sdbm/init.c @@ -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; |