From 6e1a2b321bd198be5e3dead3275c5acd29967717 Mon Sep 17 00:00:00 2001 From: pixel Date: Mon, 23 Dec 2002 17:04:42 +0000 Subject: FUCK WIN32!!! *STILL* NO VSNPRINTF!!!! WHAT THE !@$!@$@!#@#! --- lib/String.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'lib') diff --git a/lib/String.cc b/lib/String.cc index c3e8c07..4d7b0ff 100644 --- a/lib/String.cc +++ b/lib/String.cc @@ -133,7 +133,11 @@ const char * String::set(const char * s, ...) { /* This causes a warning: cannot pass objects of type `const String' through `...' but it is not really a problem. */ va_start(ap, s); +#ifdef HAVE_VSNPRINTF vsnprintf(t, BUFSIZ, s, ap); +#else + vsprintf(t, s, ap); +#endif free(str); str = Base::strdup(t); va_end(ap); @@ -145,7 +149,11 @@ const char * String::set(const String & s, ...) { va_list ap; va_start(ap, s); +#ifdef HAVE_VSNPRINTF vsnprintf(t, BUFSIZ, s.str, ap); +#else + vsprintf(t, s.str, ap); +#endif free(str); str = Base::strdup(t); va_end(ap); -- cgit v1.2.3