Module: kamailio
Branch: master
Commit: ebfacdb7d7c3dfceb68e9550eec72b89d695fd4b
URL:
https://github.com/kamailio/kamailio/commit/ebfacdb7d7c3dfceb68e9550eec72b8…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2023-03-14T12:07:27+01:00
core: tmrec fix build warning introduced at dd6339f817822cd0590aec2a9a467330bde499dd
core/utils/tmrec.c: In function 'ac_print':
core/utils/tmrec.c:275:32: warning: format '%llu' expects argument of type
'long long unsigned int', but argument 2 has type 'long unsigned int'
[-Wformat=]
275 | printf("\nSys time: %llu\nTime: %02d:%02d:%02d\n",
(uint64_t)_atp->time,
| ~~~^ ~~~~~~~~~~~~~~~~~~~~
| | |
| long long unsigned int long unsigned int
| %lu
---
Modified: src/core/utils/tmrec.c
---
Diff:
https://github.com/kamailio/kamailio/commit/ebfacdb7d7c3dfceb68e9550eec72b8…
Patch:
https://github.com/kamailio/kamailio/commit/ebfacdb7d7c3dfceb68e9550eec72b8…
---
diff --git a/src/core/utils/tmrec.c b/src/core/utils/tmrec.c
index adae68edbf..205866163f 100644
--- a/src/core/utils/tmrec.c
+++ b/src/core/utils/tmrec.c
@@ -272,7 +272,7 @@ int ac_print(ac_tm_t *_atp)
return -1;
}
- printf("\nSys time: %llu\nTime: %02d:%02d:%02d\n", (uint64_t)_atp->time,
+ printf("\nSys time: %lu\nTime: %02d:%02d:%02d\n", (uint64_t)_atp->time,
_atp->t.tm_hour, _atp->t.tm_min, _atp->t.tm_sec);
printf("Date: %s, %04d-%02d-%02d\n", _wdays[_atp->t.tm_wday],
_atp->t.tm_year+1900, _atp->t.tm_mon+1, _atp->t.tm_mday);
@@ -512,15 +512,15 @@ int tr_print(tmrec_t *_trp)
return -1;
}
printf("Recurrence definition\n-- start time ---\n");
- printf("Sys time: %llu\n", (uint64_t)_trp->dtstart);
+ printf("Sys time: %lu\n", (uint64_t)_trp->dtstart);
printf("Time: %02d:%02d:%02d\n", _trp->ts.tm_hour,
_trp->ts.tm_min, _trp->ts.tm_sec);
printf("Date: %s, %04d-%02d-%02d\n", _wdays[_trp->ts.tm_wday],
_trp->ts.tm_year+1900, _trp->ts.tm_mon+1, _trp->ts.tm_mday);
printf("---\n");
- printf("End time: %llu\n", (uint64_t)_trp->dtend);
- printf("Duration: %llu\n", (uint64_t)_trp->duration);
- printf("Until: %llu\n", (uint64_t)_trp->until);
+ printf("End time: %lu\n", (uint64_t)_trp->dtend);
+ printf("Duration: %lu\n", (uint64_t)_trp->duration);
+ printf("Until: %lu\n", (uint64_t)_trp->until);
printf("Freq: %d\n", (int)_trp->freq);
printf("Interval: %d\n", (int)_trp->interval);
if(_trp->byday)