diff src/SDL_assert.c @ 3648:a9d830c05998

Fixed build problems with gcc __attribute__.
author Ryan C. Gordon <icculus@icculus.org>
date Wed, 13 Jan 2010 07:00:20 +0000
parents c5925cd41955
children cb5b1aedb5a7
line wrap: on
line diff
--- a/src/SDL_assert.c	Wed Jan 13 06:47:17 2010 +0000
+++ b/src/SDL_assert.c	Wed Jan 13 07:00:20 2010 +0000
@@ -31,6 +31,7 @@
 #else  /* fprintf, _exit(), etc. */
 #include <stdio.h>
 #include <stdlib.h>
+#include <unistd.h>
 #endif
 
 /* We can keep all triggered assertions in a singly-linked list so we can
@@ -43,9 +44,13 @@
 
 static void 
 debug_print(const char *fmt, ...)
-//#ifdef __GNUC__
-//__attribute__((format (printf, 1, 2)))
-//#endif
+#ifdef __GNUC__
+__attribute__((format (printf, 1, 2)))
+#endif
+;
+
+static void
+debug_print(const char *fmt, ...)
 {
 #ifdef _WINDOWS
     /* Format into a buffer for OutputDebugStringA(). */