summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandru Scvortov <alexandru@rabbitmq.com>2010-11-24 13:43:15 +0000
committerAlexandru Scvortov <alexandru@rabbitmq.com>2010-11-24 13:43:15 +0000
commit51a2041df7647cc91ffc6ae8a84eb063279de4d9 (patch)
tree85b3394d30680be85b65dc5ef18e65b0aaf848d1
parent0abc8207c7299a292caaf3d8c4279c25cde8c57b (diff)
downloadrabbitmq-server-51a2041df7647cc91ffc6ae8a84eb063279de4d9.tar.gz
cosmetic
-rw-r--r--src/rabbit_amqqueue_process.erl14
-rw-r--r--src/rabbit_router.erl9
2 files changed, 12 insertions, 11 deletions
diff --git a/src/rabbit_amqqueue_process.erl b/src/rabbit_amqqueue_process.erl
index 0a3713e3..bb98fe31 100644
--- a/src/rabbit_amqqueue_process.erl
+++ b/src/rabbit_amqqueue_process.erl
@@ -445,13 +445,13 @@ confirm_message(#basic_message{guid = Guid}, State) ->
record_confirm_message(#delivery{msg_seq_no = undefined}, State) ->
State;
-record_confirm_message(#delivery{message = #basic_message {
- is_persistent = true,
- guid = Guid},
- sender = ChPid,
- msg_seq_no = MsgSeqNo},
- State = #q{q = #amqqueue{durable = true},
- guid_to_channel = GTC}) ->
+record_confirm_message(#delivery{sender = ChPid,
+ msg_seq_no = MsgSeqNo,
+ message = #basic_message {
+ is_persistent = true,
+ guid = Guid}},
+ State = #q{guid_to_channel = GTC,
+ q = #amqqueue{durable = true}}) ->
State#q{guid_to_channel = dict:store(Guid, {ChPid, MsgSeqNo}, GTC)};
record_confirm_message(_Delivery, State) ->
State.
diff --git a/src/rabbit_router.erl b/src/rabbit_router.erl
index 4a1a08e4..e36feb76 100644
--- a/src/rabbit_router.erl
+++ b/src/rabbit_router.erl
@@ -75,10 +75,11 @@ deliver(QNames, Delivery = #delivery{mandatory = false,
deliver(QNames, Delivery = #delivery{mandatory = Mandatory,
immediate = Immediate}) ->
QPids = lookup_qpids(QNames),
- {Success, _} = delegate:invoke(
- QPids, fun (Pid) ->
- rabbit_amqqueue:deliver(Pid, Delivery)
- end),
+ {Success, _} =
+ delegate:invoke(QPids,
+ fun (Pid) ->
+ rabbit_amqqueue:deliver(Pid, Delivery)
+ end),
{Routed, Handled} =
lists:foldl(fun fold_deliveries/2, {false, []}, Success),
case check_delivery(Mandatory, Immediate, {Routed, Handled}) of