diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-01-17 10:24:27 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-01-17 10:24:27 +0000 |
commit | 2bfe3c67d89f5e44aede5608f543e66140b04bae (patch) | |
tree | 8213bf5f960503f9d4e2a4260f6e7b27513ede0e /math.c | |
parent | c5393634781f0a1c1c685a11e0f9e26b32673a6e (diff) |
* math.c (domain_check): check errno first.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@26335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'math.c')
-rw-r--r-- | math.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -29,9 +29,9 @@ domain_check(x, msg) double x; const char *msg; { - if (!isnan(x)) return; - else { - if (!errno) { + if (!errno) { + if (!isnan(x)) return; + else { #if defined(EDOM) errno = EDOM; #else |