qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mcpie...@apache.org
Subject svn commit: r1442287 - /qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb
Date Mon, 04 Feb 2013 18:22:02 GMT
Author: mcpierce
Date: Mon Feb  4 18:22:02 2013
New Revision: 1442287

URL: http://svn.apache.org/viewvc?rev=1442287&view=rev
Log:
QPID-4564: Fixes decoding in Ruby.

The return type was previously being lost/ignored. Now it is returned
properly.

Modified:
    qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb

Modified: qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb?rev=1442287&r1=1442286&r2=1442287&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb (original)
+++ qpid/trunk/qpid/cpp/bindings/qpid/ruby/lib/qpid_messaging/encoding.rb Mon Feb  4 18:22:02
2013
@@ -40,13 +40,13 @@ module Qpid
 
     # Decodes and returns the message's content.
     def self.decode(message, content_type = nil)
-      content_type = message.content_type unless content_type
+      content_type = message.content_type if content_type.nil?
 
       case content_type
         when "amqp/map"
-          Cqpid.decodeMap message.message_impl
+          return Cqpid.decodeMap message.message_impl
         when "amqp/list"
-          Cqpid.decodeList message.message_impl
+          return Cqpid.decodeList message.message_impl
       end
 
       message.content



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org


Mime
View raw message