Added some basic HTTP and ip address parsing.

This commit is contained in:
2024-08-18 23:06:09 +02:00
parent 03c899f17e
commit 35e7131780
9 changed files with 497 additions and 35 deletions

View File

@@ -68,6 +68,7 @@ enum class [[nodiscard]] StreamError
IO_ERROR = 1,
NOT_SUPPORTED = 2,
CONNECTION_CLOSED = 3,
PROTOCOL_ERROR = 4,
UNKNOWN_ERROR = -1
};
@@ -430,6 +431,8 @@ inline const char* errorName(StreamError error) noexcept
return "not supported";
case StreamError::CONNECTION_CLOSED:
return "connection closed";
case StreamError::PROTOCOL_ERROR:
return "protocol error";
case StreamError::UNKNOWN_ERROR:
return "unknown error";
}