2
0
mirror of https://gitlab.isc.org/isc-projects/dhcp synced 2025-08-29 05:17:57 +00:00

cast time_t to unsigned long and use %lu instead of %u

This commit is contained in:
Mark Andrews 2010-09-14 04:01:33 +00:00
parent 6aaaf6a460
commit a96cdbe1f8

View File

@ -1492,8 +1492,8 @@ print_time(TIME t)
if ((strftime(buf1, sizeof(buf1),
"# %a %b %d %H:%M:%S %Y",
localtime(&t)) == 0) ||
(snprintf(buf, sizeof(buf), "epoch %u; %s",
since_epoch, buf1) >= sizeof(buf)))
(snprintf(buf, sizeof(buf), "epoch %lu; %s",
(unsigned long)since_epoch, buf1) >= sizeof(buf)))
return NULL;
} else {