ladybird/Userland/Libraries/LibWeb/Fetch/Infrastructure/HTTP
Timothy Flynn 1ffda6a805 LibWeb: Propagate OOM in Body::fully_read() through its error callback
Fetched bodies can be on the order of gigabytes, so rather than crashing
when we hit OOM here, we can simply invoke the error callback with a DOM
exception. We use "UnknownError" here as the spec directly supports this
for OOM errors:

    UnknownError: The operation failed for an unknown transient reason
                  (e.g. out of memory).

This is still an ad-hoc implementation. We should be using streams, and
we do have the AOs available to do so. But they need to be massaged to
be compatible with callers of Body::fully_read. And once we do use
streams, this function will become infallible - so making it infallible
here is at least a step in the right direction.
2024-04-27 07:08:14 +02:00
..
Bodies.cpp LibWeb: Propagate OOM in Body::fully_read() through its error callback 2024-04-27 07:08:14 +02:00
Bodies.h LibWeb: Propagate OOM in Body::fully_read() through its error callback 2024-04-27 07:08:14 +02:00
Headers.cpp LibWeb: Remove OOM propagation from Fetch::Infrastructure::Headers 2024-04-27 07:08:14 +02:00
Headers.h LibWeb: Remove OOM propagation from Fetch::Infrastructure::Headers 2024-04-27 07:08:14 +02:00
Methods.cpp LibWeb: Remove OOM propagation from Fetch::Infrastructure::Methods 2024-04-27 07:08:14 +02:00
Methods.h LibWeb: Remove OOM propagation from Fetch::Infrastructure::Methods 2024-04-27 07:08:14 +02:00
Requests.cpp LibWeb: Remove OOM propagation from Fetch::Infrastructure::Requests 2024-04-27 07:08:14 +02:00
Requests.h LibWeb: Remove OOM propagation from Fetch::Infrastructure::Requests 2024-04-27 07:08:14 +02:00
Responses.cpp LibWeb: Remove OOM propagation from Fetch::Infrastructure::Responses 2024-04-27 07:08:14 +02:00
Responses.h LibWeb: Remove OOM propagation from Fetch::Infrastructure::Responses 2024-04-27 07:08:14 +02:00
Statuses.cpp LibWeb: Move Fetch infra into the Web::Fetch::Infrastructure namespace 2022-07-19 00:27:35 +01:00
Statuses.h LibWeb: Move Fetch infra into the Web::Fetch::Infrastructure namespace 2022-07-19 00:27:35 +01:00