From: cherierm Date: Fri, 21 Sep 2007 16:00:21 +0000 (+0000) Subject: Visual C++ config doesn't use the gnu functions X-Git-Tag: v3.3~1117 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/65fe7ce26905cc6a4e8cc05066817e8eb0779ecc?ds=sidebyside Visual C++ config doesn't use the gnu functions git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@4674 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- diff --git a/src/portable.h b/src/portable.h index 5e755819d1..a6a02209a9 100644 --- a/src/portable.h +++ b/src/portable.h @@ -106,7 +106,7 @@ ****/ /* prototype of C99 functions */ -#ifdef HAVE_SNPRINTF +#if defined(HAVE_SNPRINTF) && defined(_MSC_VER) #include #else # if (defined(_MSC_VER) && defined(DLL_EXPORT)) @@ -131,10 +131,11 @@ extern int portable_vsnprintf(char *str, size_t str_m, const char *fmt, va_list #endif /* prototype of GNU functions */ -#ifndef __BORLANDC__ +#if !defined(__BORLANDC__) && !defined(_MSC_VER) extern int asprintf (char **ptr, const char *fmt, /*args*/ ...); extern int vasprintf (char **ptr, const char *fmt, va_list ap); #endif + extern int asnprintf (char **ptr, size_t str_m, const char *fmt, /*args*/ ...); extern int vasnprintf(char **ptr, size_t str_m, const char *fmt, va_list ap);