Fix Visual Studio 2015 and later compilation errors due to snprintf macro definition.

Closes #1508
This commit is contained in:
William S Fulton 2019-04-19 11:33:02 +01:00
commit 545ab8af08
3 changed files with 6 additions and 2 deletions

View file

@ -7,7 +7,7 @@
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#if defined(_MSC_VER) || defined(__BORLANDC__) || defined(_WATCOM)
#if (defined(_MSC_VER) && (_MSC_VER < 1900)) || defined(__BORLANDC__) || defined(_WATCOM)
# ifndef snprintf
# define snprintf _snprintf
# endif

View file

@ -35,7 +35,7 @@
%fragment("<stdio.h>", "header") %{
#include <stdio.h>
#if defined(_MSC_VER) || defined(__BORLANDC__) || defined(_WATCOM)
#if (defined(_MSC_VER) && (_MSC_VER < 1900)) || defined(__BORLANDC__) || defined(_WATCOM)
# ifndef snprintf
# define snprintf _snprintf
# endif