From 9c951cebb27d2fcfdb0adcd45cde96de4729a74b Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Sat, 12 Jan 2008 20:15:20 +0000 Subject: [PATCH] * Windows build fixes here and there. --- cucul/figfont.c | 4 ++-- cxx/caca++.cpp | 2 ++ msvc/config.h | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/cucul/figfont.c b/cucul/figfont.c index 73b428f..220b020 100644 --- a/cucul/figfont.c +++ b/cucul/figfont.c @@ -306,13 +306,13 @@ cucul_figfont_t * open_figfont(char const *path) #if !defined __KERNEL__ && defined HAVE_SNPRINTF if(!f) { - snprintf(altpath, 2047, "%s.tlf", path); + _snprintf(altpath, 2047, "%s.tlf", path); altpath[2047] = '\0'; f = _cucul_file_open(altpath, "r"); } if(!f) { - snprintf(altpath, 2047, "%s.flf", path); + _snprintf(altpath, 2047, "%s.flf", path); altpath[2047] = '\0'; f = _cucul_file_open(altpath, "r"); } diff --git a/cxx/caca++.cpp b/cxx/caca++.cpp index a50cfd7..3d937a5 100644 --- a/cxx/caca++.cpp +++ b/cxx/caca++.cpp @@ -18,6 +18,8 @@ * so on. */ +#include "config.h" + #include #include "caca++.h" diff --git a/msvc/config.h b/msvc/config.h index a7e2a49..c6799fc 100644 --- a/msvc/config.h +++ b/msvc/config.h @@ -56,3 +56,4 @@ #define inline __inline #endif #define strcasecmp stricmp +#define snprintf _snprintf \ No newline at end of file