aboutsummaryrefslogtreecommitdiffstats
path: root/lib/xmlrpc
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-04-22 13:35:43 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-04-22 13:35:43 +0000
commitd5b4cf7f798cf82cb6f33f774690b72f2a12de69 (patch)
treeeb77f128a07a4b805e9ebfa30cd91d30f5f27f96 /lib/xmlrpc
parent4e047495165c909935041e8ab869963d6e2c852a (diff)
downloadruby-d5b4cf7f798cf82cb6f33f774690b72f2a12de69.tar.gz
Use Float#finite?.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/xmlrpc')
-rw-r--r--lib/xmlrpc/create.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/xmlrpc/create.rb b/lib/xmlrpc/create.rb
index 4e4a31e890..7aa0873590 100644
--- a/lib/xmlrpc/create.rb
+++ b/lib/xmlrpc/create.rb
@@ -206,8 +206,7 @@ module XMLRPC
end
when Float
- raise "Wrong value Infinity. Not allowed!" if param.infinite?
- raise "Wrong value NaN. Not allowed!" if param.nan?
+ raise "Wrong value #{param}. Not allowed!" unless param.finite?
@writer.tag("double", param.to_s)
when Struct