summaryrefslogtreecommitdiff
path: root/ACE/ace/OS_NS_stdio.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'ACE/ace/OS_NS_stdio.cpp')
-rw-r--r--ACE/ace/OS_NS_stdio.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/ACE/ace/OS_NS_stdio.cpp b/ACE/ace/OS_NS_stdio.cpp
index bfe4c76bc30..663b412a78a 100644
--- a/ACE/ace/OS_NS_stdio.cpp
+++ b/ACE/ace/OS_NS_stdio.cpp
@@ -14,7 +14,10 @@
#include <cctype>
#include <clocale>
#include <cmath>
-#include <cwchar>
+
+#ifndef ACE_LACKS_WCHAR_H
+# include <cwchar>
+#endif
# if defined (ACE_WIN32)
@@ -503,7 +506,9 @@ ACE_OS::vaswprintf_emulation(wchar_t **bufp, const wchar_t *format, va_list argp
typedef int wint_t;
#elif !defined ACE_LACKS_WCHAR_STD_NAMESPACE
using std::wint_t;
+# ifndef ACE_LACKS_WCSRTOMBS
using std::wcsrtombs;
+# endif
#endif
namespace { // helpers for vsnprintf_emulation
@@ -736,6 +741,9 @@ namespace { // helpers for vsnprintf_emulation
static const char thousands_sep = 0;
static const char grouping[] = "";
#else
+# ifdef localeconv
+# undef localeconv
+# endif
const std::lconv *const conv = std::localeconv ();
const char thousands_sep =
conv && *conv->thousands_sep ? *conv->thousands_sep : ',';
@@ -899,7 +907,8 @@ namespace { // helpers for vsnprintf_emulation
}
else
{
-#if defined __MINGW32__ && defined __x86_64__
+#if (defined __MINGW32__ && defined __x86_64__) \
+ || (defined ACE_VXWORKS && !defined __RTP__)
// Avoid std::modf(long double, long double*) on MinGW-W64 64-bit:
// see https://sourceforge.net/p/mingw-w64/bugs/478
double int_part;