From: Alex Rousskov Date: Sat, 24 Feb 2018 00:33:37 +0000 (-0700) Subject: Bug 4822: Build failure (-Wformat) where time_t is not long int (#158) X-Git-Tag: SQUID_4_0_24~6 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=185c18dabefd1407e29c23b79fea971573c2a928;p=thirdparty%2Fsquid.git Bug 4822: Build failure (-Wformat) where time_t is not long int (#158) There is no good way to printf() time_t. AFAICT, Squid usually just casts to (long) int. TODO: Use C++ streams (with manipulators) instead. --- diff --git a/src/ipc/Kid.cc b/src/ipc/Kid.cc index 9a3cc1fa17..0a41674325 100644 --- a/src/ipc/Kid.cc +++ b/src/ipc/Kid.cc @@ -90,7 +90,9 @@ Kid::reportStopped() const if (hopeless() && Config.hopelessKidRevivalDelay) { syslog(LOG_NOTICE, "Squid Parent: %s process %d will not be restarted for %ld " "seconds due to repeated, frequent failures", - theName.termedBuf(), pid, Config.hopelessKidRevivalDelay); + theName.termedBuf(), + pid, + static_cast(Config.hopelessKidRevivalDelay)); } }