Commit 05852fb6 by Ralf W. Grosse-Kunstleve Committed by Henry Schreiner

Accommodating environments that define __STDC_WANT_LIB_EXT1__ even if…

Accommodating environments that define __STDC_WANT_LIB_EXT1__ even if __STDC_LIB_EXT1__ is not defined by the implementation. (#3151)

Follow-on to PR #3129.
parent ed5fb66b
...@@ -101,7 +101,7 @@ public: ...@@ -101,7 +101,7 @@ public:
}; };
inline std::tm *localtime_thread_safe(const std::time_t *time, std::tm *buf) { inline std::tm *localtime_thread_safe(const std::time_t *time, std::tm *buf) {
#if defined(__STDC_WANT_LIB_EXT1__) || defined(_MSC_VER) #if (defined(__STDC_LIB_EXT1__) && defined(__STDC_WANT_LIB_EXT1__)) || defined(_MSC_VER)
if (localtime_s(buf, time)) if (localtime_s(buf, time))
return nullptr; return nullptr;
return buf; return buf;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment