diff options
author | Leon Breedt <bitserf@gmail.com> | 2005-03-29 09:04:31 +0000 |
---|---|---|
committer | Leon Breedt <bitserf@gmail.com> | 2005-03-29 09:04:31 +0000 |
commit | 37270359ac5a4e09eb3caff58963327bfb699460 (patch) | |
tree | 9e0e6ae2f5c2fc4c0734401c6c5ebcacd92822de /actionwebservice/lib/action_web_service/vendor/ws | |
parent | c73a414a9abdb9943f18f6a60ed9f805e97e2ea1 (diff) | |
download | rails-37270359ac5a4e09eb3caff58963327bfb699460.tar.gz rails-37270359ac5a4e09eb3caff58963327bfb699460.tar.bz2 rails-37270359ac5a4e09eb3caff58963327bfb699460.zip |
remove wrongheaded uses of "rescue nil" if it will mask a useful exception. also include
the whole backtrace in the 500 error response body if exception reporting is turned on (the default).
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1035 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionwebservice/lib/action_web_service/vendor/ws')
-rw-r--r-- | actionwebservice/lib/action_web_service/vendor/ws/encoding/xmlrpc_encoding.rb | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/actionwebservice/lib/action_web_service/vendor/ws/encoding/xmlrpc_encoding.rb b/actionwebservice/lib/action_web_service/vendor/ws/encoding/xmlrpc_encoding.rb index b38ae81abf..122f62434f 100644 --- a/actionwebservice/lib/action_web_service/vendor/ws/encoding/xmlrpc_encoding.rb +++ b/actionwebservice/lib/action_web_service/vendor/ws/encoding/xmlrpc_encoding.rb @@ -11,10 +11,7 @@ module WS end def decode_rpc_call(obj) - method_name, params = XMLRPC::Marshal.load_call(obj) rescue nil - unless method_name && params - raise(XmlRpcError, "Malformed XML-RPC request") - end + method_name, params = XMLRPC::Marshal.load_call(obj) i = 0 params = params.map do |value| param = XmlRpcDecodedParam.new("param#{i}", value) @@ -33,10 +30,7 @@ module WS end def decode_rpc_response(obj) - return_value = XMLRPC::Marshal.load_response(obj) rescue nil - if return_value.nil? - raise(XmlRpcError, "Malformed XML-RPC response") - end + return_value = XMLRPC::Marshal.load_response(obj) [nil, XmlRpcDecodedParam.new('return', return_value)] end end |