summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatthew Sackman <matthew@lshift.net>2009-10-19 16:09:53 +0100
committerMatthew Sackman <matthew@lshift.net>2009-10-19 16:09:53 +0100
commitefbf8fca2ee1da46760e7e9689483df774065555 (patch)
treedaf844057aa5372fc91ddd3c04ce0726461cf114 /src
parent76be0ae44548d41df6839ecf72fab272840bea9f (diff)
downloadrabbitmq-server-git-efbf8fca2ee1da46760e7e9689483df774065555.tar.gz
more helpful when the bugfix fixes the bug
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_queue_index.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/rabbit_queue_index.erl b/src/rabbit_queue_index.erl
index 3471913f65..de0839fb84 100644
--- a/src/rabbit_queue_index.erl
+++ b/src/rabbit_queue_index.erl
@@ -283,7 +283,8 @@ segment_size() ->
?SEGMENT_ENTRIES_COUNT.
find_lowest_seq_id_seg_and_next_seq_id(
- State = #qistate { dir = Dir, journal_ack_dict = JAckDict }) ->
+ State = #qistate { dir = Dir, journal_ack_dict = JAckDict,
+ cur_seg_num = SegNum }) ->
SegNumsPaths = all_segment_nums_paths(Dir),
%% We don't want the lowest seq_id, merely the seq_id of the start
%% of the lowest segment. That seq_id may not actually exist, but
@@ -299,7 +300,7 @@ find_lowest_seq_id_seg_and_next_seq_id(
case SegNumsPaths of
[] -> {0, State};
_ -> {SegNum2, SegPath2} = lists:max(SegNumsPaths),
- State2 = close_file_handle_for_seg(SegNum2, State),
+ State2 = close_file_handle_for_seg(SegNum, State),
{_SDict, _AckCount, HighRelSeq} =
load_segment(SegNum2, SegPath2, JAckDict),
{1 + reconstruct_seq_id(SegNum2, HighRelSeq), State2}