From dbd1953d7ca8d3264fdef4c7909561d99a001ce1 Mon Sep 17 00:00:00 2001 From: Hirak Sarkar Date: Thu, 7 Feb 2019 14:36:05 -0500 Subject: [PATCH] fixed the OSX compilation --- include/strict_fstream.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/strict_fstream.hpp b/include/strict_fstream.hpp index 21173c7..7713e84 100644 --- a/include/strict_fstream.hpp +++ b/include/strict_fstream.hpp @@ -27,7 +27,7 @@ static std::string strerror() { buff = "Unknown error"; } -#elif (_POSIX_C_SOURCE >= 200112L || _XOPEN_SOURCE >= 600) && ! _GNU_SOURCE +#elif (_POSIX_C_SOURCE >= 200112L || _XOPEN_SOURCE >= 600 || defined(__APPLE__)) && ! _GNU_SOURCE // XSI-compliant strerror_r() if (strerror_r(errno, &buff[0], buff.size()) != 0) {