From: H.J. Lu Date: Fri, 19 Dec 2014 22:05:35 +0000 (-0800) Subject: Replace %ld with %jd and cast to intmax_t X-Git-Tag: glibc-2.21~136 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=126f6c7288b7262fd84a2026a33f36f0cc495871;p=glibc.git Replace %ld with %jd and cast to intmax_t --- diff --git a/ChangeLog b/ChangeLog index a228b9e623..ce76c8d819 100644 --- a/ChangeLog +++ b/ChangeLog @@ -27,6 +27,7 @@ * sysdeps/pthread/tst-timer.c (main): Likewise. * time/clocktest.c (main): Likewise. * time/tst-posixtz.c (do_test): Likewise. + * timezone/tst-timezone.c (main): Likewise. 2014-12-30 Andrew Senkevich H.J. Lu diff --git a/timezone/tst-timezone.c b/timezone/tst-timezone.c index b5edfff5f8..135a72fc9a 100644 --- a/timezone/tst-timezone.c +++ b/timezone/tst-timezone.c @@ -126,8 +126,8 @@ main (int argc, char ** argv) strcpy (envstring, "TZ=Europe/London"); putenv (envstring); t = mktime (&tmBuf); - snprintf (buf, sizeof (buf), "TZ=%s %ld %d %d %d %d %d %d %d %d %d", - getenv ("TZ"), t, + snprintf (buf, sizeof (buf), "TZ=%s %jd %d %d %d %d %d %d %d %d %d", + getenv ("TZ"), (intmax_t) t, tmBuf.tm_sec, tmBuf.tm_min, tmBuf.tm_hour, tmBuf.tm_mday, tmBuf.tm_mon, tmBuf.tm_year, tmBuf.tm_wday, tmBuf.tm_yday, tmBuf.tm_isdst); @@ -149,8 +149,8 @@ main (int argc, char ** argv) strcpy (envstring, "TZ=GMT"); /* No putenv call needed! */ t = mktime (&tmBuf); - snprintf (buf, sizeof (buf), "TZ=%s %ld %d %d %d %d %d %d %d %d %d", - getenv ("TZ"), t, + snprintf (buf, sizeof (buf), "TZ=%s %jd %d %d %d %d %d %d %d %d %d", + getenv ("TZ"), (intmax_t) t, tmBuf.tm_sec, tmBuf.tm_min, tmBuf.tm_hour, tmBuf.tm_mday, tmBuf.tm_mon, tmBuf.tm_year, tmBuf.tm_wday, tmBuf.tm_yday, tmBuf.tm_isdst);