mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 12:19:54 +00:00
LibCore: Don't discard subsequent results in Socket::resolve_host
Previously, we only returned the first result that looked like an IPv6 or IPv4 address. This cropped up when attempting to connect to https://cxbyte.me/ whilst IPv6 on the server wasn't working. Since we only returned the first result, which happened to be the IPv6 address, we wasn't able to connect. Returning all results allows curl to attempt to connect to a different IP if one of them isn't working, and potentially make a successful connection.
This commit is contained in:
parent
93e2babc64
commit
08246bfa8c
Notes:
github-actions[bot]
2025-02-28 14:15:30 +00:00
Author: https://github.com/Lubrsi
Commit: 08246bfa8c
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3731
Reviewed-by: https://github.com/alimpfard ✅
3 changed files with 33 additions and 18 deletions
|
@ -58,7 +58,7 @@ public:
|
|||
|
||||
// FIXME: This will need to be updated when IPv6 socket arrives. Perhaps a
|
||||
// base class for all address types is appropriate.
|
||||
static ErrorOr<Variant<IPv4Address, IPv6Address>> resolve_host(ByteString const&, SocketType);
|
||||
static ErrorOr<Vector<Variant<IPv4Address, IPv6Address>>> resolve_host(ByteString const&, SocketType);
|
||||
|
||||
Function<void()> on_ready_to_read;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue