From 63acf4f174fd82fb80db34870acfce859b56ceda Mon Sep 17 00:00:00 2001 From: Antony Polukhin Date: Sat, 25 Aug 2012 19:07:46 +0000 Subject: [PATCH] Fix compilation of lexical cast with MSVC 2003 (refs #7255) [SVN r80210] --- include/boost/lexical_cast.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/boost/lexical_cast.hpp b/include/boost/lexical_cast.hpp index 892dd9c..b164068 100644 --- a/include/boost/lexical_cast.hpp +++ b/include/boost/lexical_cast.hpp @@ -1361,7 +1361,7 @@ namespace boost { if (put_inf_nan(begin, end, val)) return true; const double val_as_double = val; end = begin + -#if defined(_MSC_VER) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) +#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) sprintf_s(begin, end-begin, #else sprintf(begin, @@ -1374,7 +1374,7 @@ namespace boost { { using namespace std; if (put_inf_nan(begin, end, val)) return true; end = begin + -#if defined(_MSC_VER) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) +#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) sprintf_s(begin, end-begin, #else sprintf(begin, @@ -1388,7 +1388,7 @@ namespace boost { { using namespace std; if (put_inf_nan(begin, end, val)) return true; end = begin + -#if defined(_MSC_VER) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) +#if defined(_MSC_VER) && (_MSC_VER >= 1400) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) sprintf_s(begin, end-begin, #else sprintf(begin,