From 1fdc4ceee6f14ceebc4cb2affa9ae9dd6b7cc523 Mon Sep 17 00:00:00 2001 From: "Roger A. Light" Date: Tue, 19 Aug 2014 01:11:22 +0100 Subject: [PATCH] Check expiration every hour regardless of the duration. --- src/loop.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/loop.c b/src/loop.c index 94527b1c..3d3a93e7 100644 --- a/src/loop.c +++ b/src/loop.c @@ -84,7 +84,7 @@ int mosquitto_main_loop(struct mosquitto_db *db, int *listensock, int listensock #endif if(db->config->persistent_client_expiration > 0){ - expiration_check_time = time(NULL) + db->config->persistent_client_expiration; + expiration_check_time = time(NULL) + 3600; } while(run){ @@ -250,7 +250,7 @@ int mosquitto_main_loop(struct mosquitto_db *db, int *listensock, int listensock } } } - expiration_check_time = time(NULL) + db->config->persistent_client_expiration; + expiration_check_time = time(NULL) + 3600; } mqtt3_db_message_timeout_check(db, db->config->retry_interval);