From f1306b1c19f43a60e4d9d2bf7c87d4cd8e97badc Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Thu, 11 Jul 2013 23:17:52 -0400 Subject: [PATCH] Attempt to fix a compiler warning on Haiku. (if this works...Haiku generates no warnings. I know, right?!?) --- src/test/SDL_test_log.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/test/SDL_test_log.c b/src/test/SDL_test_log.c index d184396a3..c854c0f7d 100644 --- a/src/test/SDL_test_log.c +++ b/src/test/SDL_test_log.c @@ -55,11 +55,12 @@ char *SDLTest_TimestampToString(const time_t timestamp) time_t copy; static char buffer[64]; struct tm *local; + const char *fmt = "%x %X"; - SDL_memset(buffer, 0, sizeof(buffer));\ + SDL_memset(buffer, 0, sizeof(buffer)); copy = timestamp; local = localtime(©); - strftime(buffer, sizeof(buffer), "%x %X", local); + strftime(buffer, sizeof(buffer), fmt, local); return buffer; }