summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2011-01-26 13:42:44 +0000
committerMatthias Radestock <matthias@rabbitmq.com>2011-01-26 13:42:44 +0000
commitbef227e0c6049c1af04b5e6152e5c8981c9f4348 (patch)
tree75876d0b91c3648d2c570538e4f7378cf4a22314
parent08478a808204cf9033cc486edd91eaab6336568b (diff)
downloadrabbitmq-server-bef227e0c6049c1af04b5e6152e5c8981c9f4348.tar.gz
simplify
-rw-r--r--src/rabbit_msg_store.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rabbit_msg_store.erl b/src/rabbit_msg_store.erl
index 18227be1..df403fbf 100644
--- a/src/rabbit_msg_store.erl
+++ b/src/rabbit_msg_store.erl
@@ -756,7 +756,7 @@ handle_cast({write, CRef, Guid},
{ignore, Loc, State1} ->
ok = maybe_remove_from_cache(Guid, Loc, Msg, State1),
State;
- {confirm, Loc, File, State1} ->
+ {confirm, Loc = #msg_location { file = File }, State1} ->
ok = maybe_remove_from_cache(Guid, Loc, Msg, State1),
client_confirm_if_on_disk(CRef, Guid, File, State1)
end);
@@ -927,14 +927,14 @@ write_action({Mask, #msg_location { ref_count = 0, file = File,
{_Mask, [#file_summary {}]} ->
ok = index_update_ref_count(Guid, 1, State),
State1 = adjust_valid_total_size(File, TotalSize, State),
- {confirm, Loc, File, State1}
+ {confirm, Loc, State1}
end;
-write_action({_Mask, #msg_location { ref_count = RefCount, file = File } = Loc},
+write_action({_Mask, #msg_location { ref_count = RefCount } = Loc},
Guid, State) ->
ok = index_update_ref_count(Guid, RefCount + 1, State),
%% We already know about it, just update counter. Only update
%% field otherwise bad interaction with concurrent GC
- {confirm, Loc, File, State}.
+ {confirm, Loc, State}.
write_message(CRef, Guid, Msg, State) ->
write_message(Guid, Msg, record_pending_confirm(CRef, Guid, State)).