diff options
author | ocean <ocean@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-01-06 08:24:04 +0000 |
---|---|---|
committer | ocean <ocean@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-01-06 08:24:04 +0000 |
commit | 8531657741a5d8fb3443ccfe54f62d551dfa0aca (patch) | |
tree | 443b6b19e2363b10787e1a92cbbc98b15c5555e9 /random.c | |
parent | a12ac9b17de142cecd8672fc1107c4c5fdcc406d (diff) |
* random.c (random_seed): O_NONBLOCK isn't defined on some
platforms. [ruby-dev:25417]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'random.c')
-rw-r--r-- | random.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -275,7 +275,10 @@ random_seed() memset(digits, 0, big->len * SIZEOF_BDIGITS); #ifdef S_ISCHR - if ((fd = open("/dev/urandom", O_RDONLY|O_NONBLOCK + if ((fd = open("/dev/urandom", O_RDONLY +#ifdef O_NONBLOCK + |O_NONBLOCK +#endif #ifdef O_NOCTTY |O_NOCTTY #endif |