summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_amqqueue.erl8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/rabbit_amqqueue.erl b/src/rabbit_amqqueue.erl
index 102ea13b33..80dcb79a4a 100644
--- a/src/rabbit_amqqueue.erl
+++ b/src/rabbit_amqqueue.erl
@@ -214,7 +214,13 @@ internal_declare(Q = #amqqueue{name = QueueName}, false) ->
case mnesia:read({rabbit_durable_queue, QueueName}) of
[] -> ok = store_queue(Q),
B = add_default_binding(Q),
- fun (Tx) -> B(Tx), Q end;
+ fun (Tx) ->
+ R = B(Tx),
+ case Tx of
+ transaction -> R;
+ _ -> Q
+ end
+ end;
%% Q exists on stopped node
[_] -> rabbit_misc:const(not_found)
end;