summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_limiter.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rabbit_limiter.erl b/src/rabbit_limiter.erl
index d91893b0e8..20f543599a 100644
--- a/src/rabbit_limiter.erl
+++ b/src/rabbit_limiter.erl
@@ -131,7 +131,7 @@ handle_cast({decrement_capacity, Magnitude}, State = #lim{in_use = InUse}) ->
if
ShouldNotify ->
notify_queues(State),
- {noreply, State#lim{queues = sets:new(), in_use = InUse - 1}};
+ {noreply, State#lim{queues = sets:new(), in_use = InUse - Magnitude}};
true ->
{noreply, NewState}
end.