-
-
Notifications
You must be signed in to change notification settings - Fork 333
Open
Labels
A-headersArea: HTTP headersArea: HTTP headersE-easyEffort: easy. Start here :DEffort: easy. Start here :DS-docsSeverity: docs. Explain things better.Severity: docs. Explain things better.
Description
HeaderMap
has a capacity limit of 24576 headers. Adding any more headers triggers a panic when reserving more capacity.
I can't see any way to prevent the panic when handling incoming headers, except to hard-wire a check for this value into calling code.
It would be useful to expose this value as a public constant.
At the very least it should be documented. Currently HeaderMap::reserve
says "Panics if the new allocation size overflows usize." This should be "Panics if the new allocation size is greater than 24576."
Metadata
Metadata
Assignees
Labels
A-headersArea: HTTP headersArea: HTTP headersE-easyEffort: easy. Start here :DEffort: easy. Start here :DS-docsSeverity: docs. Explain things better.Severity: docs. Explain things better.