summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniil Fedotov <dfedotov@pivotal.io>2017-06-13 17:23:10 +0100
committerDaniil Fedotov <dfedotov@pivotal.io>2017-06-13 17:23:10 +0100
commit41a396e26e3d5fea88ee3e9e375a2ef791bf1b21 (patch)
treea0a7f43b65771636ac12e00eda33d852b901e600 /src
parent10da251c856468e4690b37d33bb2fd81e2b37a58 (diff)
downloadrabbitmq-server-git-41a396e26e3d5fea88ee3e9e375a2ef791bf1b21.tar.gz
Do not assume `#resource` is a 4-element tuple.
The queue_name_to_binary compat function is used in migration functions, so `resource` record can change. Still in the old version, from which we are upgrading it will be a 4-element tuple.
Diffstat (limited to 'src')
-rw-r--r--src/term_to_binary_compat.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/term_to_binary_compat.erl b/src/term_to_binary_compat.erl
index a3e1045623..8a74bde3e0 100644
--- a/src/term_to_binary_compat.erl
+++ b/src/term_to_binary_compat.erl
@@ -20,7 +20,7 @@
-export([queue_name_to_binary/1]).
-queue_name_to_binary(#resource{kind = queue} = {resource, VHost, queue, Name}) ->
+queue_name_to_binary(#resource{kind = queue, virtual_host = VHost, name = Name}) ->
VHostBSize = byte_size(VHost),
NameBSize = byte_size(Name),
<<131, %% Binary format "version"