mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-25 15:21:54 +00:00
Fix MinGW issues, take 2.
This commit is contained in:
parent
0ffcec0090
commit
9c47f3e057
@ -301,7 +301,12 @@ int fmt::internal::StrError(
|
||||
if (message == buffer && strlen(buffer) == buffer_size - 1)
|
||||
result = ERANGE;
|
||||
buffer = message;
|
||||
#elif defined(_WIN32) && !defined(__MINGW32__)
|
||||
#elif __MINGW32__
|
||||
errno = 0;
|
||||
(void)buffer_size;
|
||||
buffer = strerror(error_code);
|
||||
result = errno;
|
||||
#elif _WIN32
|
||||
result = strerror_s(buffer, buffer_size, error_code);
|
||||
// If the buffer is full then the message is probably truncated.
|
||||
if (result == 0 && std::strlen(buffer) == buffer_size - 1)
|
||||
|
Loading…
Reference in New Issue
Block a user