summaryrefslogtreecommitdiff
path: root/cpp/bindings
diff options
context:
space:
mode:
authorDarryl L. Pierce <mcpierce@apache.org>2013-03-18 19:15:17 +0000
committerDarryl L. Pierce <mcpierce@apache.org>2013-03-18 19:15:17 +0000
commit7f952ae1ba814f29ee7107fdccb83d17eb13a629 (patch)
treec986b1d9b02f9ec82a2721fe8dec3a98a620df3f /cpp/bindings
parent1553f776c7f0c2b663017b40f321288d32f96047 (diff)
downloadqpid-python-7f952ae1ba814f29ee7107fdccb83d17eb13a629.tar.gz
QPID-4493: Fixes memory leak in Perl bindings.
Contributed by: Jimmy Jones <jimmyjones2@gmx.co.uk> git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1457923 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/bindings')
-rw-r--r--cpp/bindings/qpid/perl/t/Message.t7
1 files changed, 7 insertions, 0 deletions
diff --git a/cpp/bindings/qpid/perl/t/Message.t b/cpp/bindings/qpid/perl/t/Message.t
index 15baafb446..c656a7cf90 100644
--- a/cpp/bindings/qpid/perl/t/Message.t
+++ b/cpp/bindings/qpid/perl/t/Message.t
@@ -265,6 +265,13 @@ $map = qpid::messaging::decode_map($message);
ok ($map->{name} eq "Euro=\x{20AC}",
"Unicode strings encoded correctly.");
+# Maps inside maps should work
+$content = { id => 1234, name => { first => "tom" } };
+qpid::messaging::encode($content, $message);
+$map = qpid::messaging::decode_map($message);
+ok ($map->{name}{first} eq "tom",
+ "Map inside map encoded correctly.");
+
# Setting the content as a hash automatically encodes it
($content) = {"id" => "1234", "name" => "qpid"};
$message->set_content($content);