diff options
author | Simon MacMullen <simon@rabbitmq.com> | 2014-08-08 16:30:38 +0100 |
---|---|---|
committer | Simon MacMullen <simon@rabbitmq.com> | 2014-08-08 16:30:38 +0100 |
commit | a1884877808f6c34c349e132b31db9e45de347d0 (patch) | |
tree | d49a729fcf257334a818a502a373b87061f048f0 | |
parent | a7df1553ff876998a5171df3ef9e636123c91e51 (diff) | |
download | rabbitmq-server-a1884877808f6c34c349e132b31db9e45de347d0.tar.gz |
Dialyzer points out that the false branch cannot happen. In bug 26204 we removed that distinction (cancelling an already fired timer); cancel_timer now only returns 'ok'.
-rw-r--r-- | src/rabbit_amqqueue_process.erl | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/rabbit_amqqueue_process.erl b/src/rabbit_amqqueue_process.erl index 63b18655..89b3e554 100644 --- a/src/rabbit_amqqueue_process.erl +++ b/src/rabbit_amqqueue_process.erl @@ -392,10 +392,8 @@ ensure_ttl_timer(Expiry, State = #q{ttl_timer_ref = undefined, ensure_ttl_timer(Expiry, State = #q{ttl_timer_ref = TRef, ttl_timer_expiry = TExpiry}) when Expiry + 1000 < TExpiry -> - case rabbit_misc:cancel_timer(TRef) of - false -> State; - _ -> ensure_ttl_timer(Expiry, State#q{ttl_timer_ref = undefined}) - end; + rabbit_misc:cancel_timer(TRef), + ensure_ttl_timer(Expiry, State#q{ttl_timer_ref = undefined}); ensure_ttl_timer(_Expiry, State) -> State. |