1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-01 08:18:12 +00:00

LibWeb: Trim leading and trailing HTTP whitespace bytes

The XMLHttpRequest specification specifices that header values should be
normalized by trimming leading and trailing HTTP whitespace bytes.
This commit is contained in:
Kenneth Myhra 2022-04-04 10:42:12 +02:00 committed by Linus Groh
parent fccea8888e
commit 1ca1a73d67
2 changed files with 3 additions and 2 deletions

View file

@ -19,6 +19,8 @@
namespace Web::XHR {
static constexpr Array<u8, 4> http_whitespace_bytes = { '\t', '\n', '\r', ' ' };
class XMLHttpRequest final
: public RefCounted<XMLHttpRequest>
, public Weakable<XMLHttpRequest>