NetServices: Rework parsing of content-length and move to HttpParser

This fixes a bug in the HttpAuthTest, and in general, moves responsibility of determining
the shape and size of the content to the right place.

Still to do is to fix the case where there really is a variable length content. This will
now probably error out as a connection closed error.

Change-Id: I13c20028e834cc9af8c7bc1d7d7613bf60838e64
This commit is contained in:
Niels Sascha Reedijk
2022-08-08 07:58:45 +01:00
parent 9cb56a4881
commit 7b1d966cf2
7 changed files with 173 additions and 128 deletions
+13
View File
@@ -605,6 +605,19 @@ namespace Network {
*/
/*!
\fn size_t BHttpFields::CountFields(const std::string_view &name) const noexcept
\brief Cound the number of fields that have this \a name.
\param name The name of the field you are looking for. Name matching will be done case
insensitively.
\return The number of field with the \a name.
\since Haiku R1
*/
//! @}