Skip to content

Commit

Permalink
Only make keepalive checks every 5 seconds.
Browse files Browse the repository at this point in the history
  • Loading branch information
ralight committed Nov 5, 2020
1 parent 23d3c26 commit 693f6ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/keepalive.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ void keepalive__check(struct mosquitto_db *db, time_t now)
{
struct mosquitto *context, *ctxt_tmp;

if(last_keepalive_check != now){
if(last_keepalive_check + 5 < now){
last_keepalive_check = now;

/* FIXME - this needs replacing with something more efficient */
Expand Down

0 comments on commit 693f6ad

Please sign in to comment.