bad_socket¶
-
struct
mikrotik::api::bad_socket: public exception¶ : Exception to describe a failure that occurred while using sockets
An exception wrapping all failures that originate from the resident socket implementation. On POSIX implementations some errno values are translated to english, while on WinSock2 they are just the error’s names, although some warnings may get translated in the future.
- Since
v1.0.0
Public Functions
-
bad_socket(std::string_view reason = "unknown error")¶ Creates a bad_socket exception with the provided reason for the error.
- Since
v1.0.0
- Parameters
reason: A string describing the error
-
const char *
what() const noexcept override¶ Returns a formatted error message about the error
- Return
A c-string with the error message
- Since
v1.0.0