Replace fmt::system_error with std::system_error

This commit is contained in:
Victor Zverovich committed 2021-05-07 08:33:39 -07:00
1 parent 4b885c8633
commit 16f2ef91ab
13 files changed
+82 -249

No files matched your search

-12
View File
@@ -9,18 +9,6 @@
#include <cstring>
std::string get_system_error(int error_code) {
#if defined(__MINGW32__) || !defined(_WIN32)
return strerror(error_code);
#else
enum { buffer_size = 200 };
char buffer[buffer_size];
if (strerror_s(buffer, buffer_size, error_code))
throw std::exception("strerror_s failed");
return buffer;
#endif
}
const char* const file_content = "Don't panic!";
fmt::buffered_file open_buffered_file(FILE** fp) {