Переглянути джерело

p_usrloc: cast to uint64_t when using time_t value

Daniel-Constantin Mierla 2 роки тому
батько
коміт
e29ce59446
1 змінених файлів з 5 додано та 2 видалено
  1. 5 2
      src/modules/p_usrloc/ul_check.c

+ 5 - 2
src/modules/p_usrloc/ul_check.c

@@ -19,6 +19,8 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
+#include <stdint.h>
+
 #include "../../core/mem/shm_mem.h"
 #include "ul_check.h"
 #include "time.h"
@@ -130,11 +132,12 @@ int set_must_reconnect(void) {
 }
 
 
-int must_retry(time_t * timer, time_t interval){
+int must_retry(time_t *timer, time_t interval){
 	if(!timer){
 		return -1;
 	}
-	LM_DBG("must_retry: time is at %i, retry at %i.\n", (int)time(NULL), (int)(*timer));
+	LM_DBG("must_retry: time is at %llu, retry at %llu.\n", (uint64_t)time(NULL),
+			(uint64_t)(*timer));
 	if(*timer <= time(NULL)){
 		*timer = time(NULL) + interval;
 		return 1;