Explorar o código

Issue #460 - Timer Tick at interval of (Keepalive * 1.5)/2

Feng %!s(int64=10) %!d(string=hai) anos
pai
achega
cf4dfe632f
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/emqttd_protocol.erl

+ 1 - 1
src/emqttd_protocol.erl

@@ -307,7 +307,7 @@ send_willmsg(ClientId, WillMsg) ->
 start_keepalive(0) -> ignore;
 
 start_keepalive(Sec) when Sec > 0 ->
-    self() ! {keepalive, start, round(Sec * 1.2)}.
+    self() ! {keepalive, start, round(Sec * 0.75)}.
 
 %%--------------------------------------------------------------------
 %% Validate Packets