Module: kamailio
Branch: master
Commit: c78910a71226f3a567ad396ce5e834036ce75f97
URL:
https://github.com/kamailio/kamailio/commit/c78910a71226f3a567ad396ce5e8340…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2023-02-16T12:07:26+01:00
uac: cast to uint64_t when using time_t value
---
Modified: src/modules/uac/uac_reg.c
---
Diff:
https://github.com/kamailio/kamailio/commit/c78910a71226f3a567ad396ce5e8340…
Patch:
https://github.com/kamailio/kamailio/commit/c78910a71226f3a567ad396ce5e8340…
---
diff --git a/src/modules/uac/uac_reg.c b/src/modules/uac/uac_reg.c
index 02138101c07..c9df873ab16 100644
--- a/src/modules/uac/uac_reg.c
+++ b/src/modules/uac/uac_reg.c
@@ -26,6 +26,7 @@
*/
#include <time.h>
+#include <stdint.h>
#include "../../core/dprint.h"
#include "../../core/timer.h"
@@ -1882,7 +1883,7 @@ static int rpc_uac_reg_add_node_helper(rpc_t* rpc, void* ctx,
reg_uac_t *reg, ti
rpc->fault(ctx, 500, "Internal error creating rpc");
return -1;
}
- if (rpc->struct_add(th, "SSSSSSSSSSddddddSS",
+ if (rpc->struct_add(th, "SSSSSSSSSSJdddJdSS",
"l_uuid", ®->l_uuid,
"l_username", ®->l_username,
"l_domain", ®->l_domain,
@@ -1896,11 +1897,11 @@ static int rpc_uac_reg_add_node_helper(rpc_t* rpc, void* ctx,
reg_uac_t *reg, ti
®->auth_ha1:&none,
"auth_proxy", (reg->auth_proxy.len)?
®->auth_proxy:&none,
- "expires", (int)reg->expires,
+ "expires", (uint64_t)reg->expires,
"flags", (int)reg->flags,
"diff_expires", (int)(reg->timer_expires - tn),
"timer_expires", (int)reg->timer_expires,
- "reg_init", (int)reg->reg_init,
+ "reg_init", (uint64_t)reg->reg_init,
"reg_delay", (int)reg->reg_delay,
"contact_addr", (reg->contact_addr.len)?
®->contact_addr:&none,