Handle the {ok, I} return

This commit is contained in:
Feng Lee 2017-02-23 17:26:29 +08:00
parent e972103f74
commit 5ef4fce141
1 changed files with 2 additions and 2 deletions

View File

@ -25,8 +25,8 @@
-spec(conn_max_gc_count() -> integer()). -spec(conn_max_gc_count() -> integer()).
conn_max_gc_count() -> conn_max_gc_count() ->
case emqttd:env(conn_force_gc_count) of case emqttd:env(conn_force_gc_count) of
undefined -> undefined; {ok, I} when I > 0 -> I + rand:uniform(I);
I when I > 0 -> I + rand:uniform(I) undefined -> undefined
end. end.
-spec(reset_conn_gc_count(pos_integer(), tuple()) -> tuple()). -spec(reset_conn_gc_count(pos_integer(), tuple()) -> tuple()).