diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-01-11 09:18:54 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-01-11 09:18:54 +0000 |
commit | d5507529fbcad12a37714a0a3f39d2f9f2e4b7ce (patch) | |
tree | 09c1328183e4ac51711b93522b53b7f0c62d5b4d /bignum.c | |
parent | a9987f8ce6ef8edee377e2bf4fc9b7a5b61a1045 (diff) | |
download | ruby-d5507529fbcad12a37714a0a3f39d2f9f2e4b7ce.tar.gz ruby-d5507529fbcad12a37714a0a3f39d2f9f2e4b7ce.tar.xz ruby-d5507529fbcad12a37714a0a3f39d2f9f2e4b7ce.zip |
* re.c (match_select): should propagate taintness.
* hash.c (rb_hash_set_default): Hash#default= should return the
new value.
* string.c (rb_str_to_i): accepts optional base argument. [new]
* numeric.c (rb_fix2str): should not handle negative fixnum values
int32 via calling sprintf() directly.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@1985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bignum.c')
-rw-r--r-- | bignum.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -6,7 +6,7 @@ $Date$ created at: Fri Jun 10 00:48:55 JST 1994 - Copyright (C) 1993-2001 Yukihiro Matsumoto + Copyright (C) 1993-2002 Yukihiro Matsumoto **********************************************************************/ @@ -351,7 +351,7 @@ rb_str2inum(str, base) p[len] = '\0'; s = p; } - if (len != strlen(s)) { + if (base == 0 && len != strlen(s)) { rb_raise(rb_eArgError, "string for Integer contains null byte"); } return rb_cstr2inum(s, base); |