| 13 | #include "Exception.hpp" |
| 14 | |
| 15 | static std::string explicitGenerateErrString(const std::string& what, int err, const char* str) { |
| 16 | std::stringstream ss; |
| 17 | ss << "could not " << what << ": " << err << "/" << str; |
| 18 | return ss.str(); |
| 19 | } |
| 20 | |
| 21 | static std::string generateErrString(const std::string& what, int err) { |
| 22 | return explicitGenerateErrString(what, err, (std::string(translateErrno(err)) + "=" + safe_strerror(err)).c_str()); |
no outgoing calls
no test coverage detected