summaryrefslogtreecommitdiff
path: root/random.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-10-04 01:24:01 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-10-04 01:24:01 +0000
commit25eebc3ad5579b1f1da0e355b2d150769ac9396f (patch)
tree027a4a1bde1c576a83b1436ea45bae4efd66d235 /random.c
parentb259e449d14e47e225960ec0fce12a5b2c1bec6d (diff)
downloadruby-25eebc3ad5579b1f1da0e355b2d150769ac9396f.tar.gz
* random.c (rand_init): This checks the value is in 32bit or not,
so use int32_t, not int. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'random.c')
-rw-r--r--random.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/random.c b/random.c
index c630e9b6b5..dbc77d0532 100644
--- a/random.c
+++ b/random.c
@@ -403,7 +403,7 @@ rand_init(struct MT *mt, VALUE vseed)
fixnum_seed = -fixnum_seed;
buf[0] = (unsigned int)(fixnum_seed & 0xffffffff);
#if SIZEOF_LONG > SIZEOF_INT32
- if ((long)(int)fixnum_seed != fixnum_seed) {
+ if ((long)(int32_t)fixnum_seed != fixnum_seed) {
if ((buf[1] = (unsigned int)(fixnum_seed >> 32)) != 0) ++len;
}
#endif