ladybird/Userland/Libraries/LibURL
Shannon Booth ff71d8f2c9 LibURL+LibWeb: Pass a mutable reference URL to URL parser
If given, the spec expects the input URL to be manipulated on the fly
as it is being parsed, and may ignore any errors thrown by the URL
parser.

Previously, we were not exactly following the specs assumption here
which resulted in us needed to make awkward copies of the URL in these
situations.

For most cases this is not an issue. But it does cause problems for
situations where URL parsing would result in a failure (which is
ignored by the caller), and the URL is _partially_ updated
while parsing.

Such a situation can occur when setting the host of an href alongside a
port number which is not valid. It is expected that this situation will
result in the host being updates - but not the port number.

Adjust the URL parser API so that it mutates the URL given (if any), and
adjust the callers accordingly.

Fixes two tests on https://wpt.live/url/url-setters-a-area.window.html
2024-08-13 14:14:34 +02:00
..
CMakeLists.txt LibTextCodec+LibURL: Implement utf-8 and euc-jp encoders 2024-08-08 17:49:58 +01:00
Forward.h LibURL: Add BlobURLEntry to URL 2024-05-12 15:46:29 -06:00
Parser.cpp LibURL+LibWeb: Pass a mutable reference URL to URL parser 2024-08-13 14:14:34 +02:00
Parser.h LibURL+LibWeb: Pass a mutable reference URL to URL parser 2024-08-13 14:14:34 +02:00
URL.cpp LibURL: Make percent_encode return a String 2024-08-10 10:39:43 +02:00
URL.h LibURL: Make percent_encode return a String 2024-08-10 10:39:43 +02:00