aboutsummaryrefslogtreecommitdiffstats
path: root/random.c
diff options
context:
space:
mode:
authorkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-07-14 15:01:39 +0000
committerkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-07-14 15:01:39 +0000
commitff3016bd3618415eea3ea1643178ef6be2b572b9 (patch)
tree26260134a4107e2b8d9bf018e72602587dc584d1 /random.c
parent63c4b2273107c48360ca440b4faf161bc8310289 (diff)
downloadruby-ff3016bd3618415eea3ea1643178ef6be2b572b9.tar.gz
fix compile error with clang
* random.c (fill_random_bytes_syscall): fix compile error with clang. [ruby-core:69931] [Bug #11343] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51240 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 8e03e8f590..64524561f5 100644
--- a/random.c
+++ b/random.c
@@ -521,7 +521,7 @@ fill_random_bytes_syscall(void *seed, size_t size)
{
static rb_atomic_t try_syscall = 1;
if (try_syscall) {
- int ret;
+ long ret;
errno = 0;
ret = syscall(SYS_getrandom, seed, size, 0);
if (errno == ENOSYS) {