summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Sackman <matthew@lshift.net>2010-01-21 10:51:34 +0000
committerMatthew Sackman <matthew@lshift.net>2010-01-21 10:51:34 +0000
commit201957e436b9b41c415824e0b16e7b83979476a2 (patch)
treea119589fb15b52f3913e689b53bf3116984b78a6
parent8f6837ef5bd9ba97b7e8513307e9a1b692511c7a (diff)
downloadrabbitmq-server-git-201957e436b9b41c415824e0b16e7b83979476a2.tar.gz
fixed
-rw-r--r--src/file_handle_cache.erl3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/file_handle_cache.erl b/src/file_handle_cache.erl
index 144d383109..1b39d29697 100644
--- a/src/file_handle_cache.erl
+++ b/src/file_handle_cache.erl
@@ -738,7 +738,8 @@ process_obtains(State = #fhc_state { limit = Limit, count = Count,
Take = ObtainsLen - lists:min([ObtainsLen, Limit - Count]),
{ObtainsNew, ObtainableRev} = lists:split(Take, Obtains),
[gen_server:reply(From, ok) || From <- ObtainableRev],
- State #fhc_state { count = Count + Take, obtains = ObtainsNew }.
+ State #fhc_state { count = Count + length(ObtainableRev),
+ obtains = ObtainsNew }.
maybe_reduce(State = #fhc_state { limit = Limit, count = Count,
elders = Elders })