mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
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
This commit is contained in:
parent
4ba1038af3
commit
b091903c5c
2 changed files with 6 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
Wed Jul 15 00:00:00 2015 Kazuhiro NISHIYAMA <zn@mbf.nifty.com>
|
||||
|
||||
* random.c (fill_random_bytes_syscall): fix compile error with
|
||||
clang. [ruby-core:69931] [Bug #11343]
|
||||
|
||||
Tue Jul 14 11:22:42 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* lib/webrick/utils.rb (WEBrick::Utils::TimeoutHandler#register):
|
||||
|
|
2
random.c
2
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) {
|
||||
|
|
Loading…
Reference in a new issue