Skip to content

test(libSceNet): accept every unusable IPv6 loopback error in guest_sce_net - #7987

Merged
oneandonlydean merged 1 commit into
boykopovar:mainfrom
MarrasFederico:fix/sce-net-ipv6-loopback-errors
Oct 20, 2026
Merged

oneandonlydean merged 1 commit into
boykopovar:mainfrom
MarrasFederico:fix/sce-net-ipv6-loopback-errors

Conversation

@MarrasFederico

Copy link
Copy Markdown
Contributor

What

guest_sce_net aborts in CheckUnspecifiedIpv6 on a Linux host whose kernel has IPv6 but where ::1 is unusable. The test skips its IPv6 checks when sceNetSendto to ::1 fails and HostIpv6LoopbackUnavailable confirms the host cannot reach ::1. The host probe accepts EADDRNOTAVAIL, ENETUNREACH and EHOSTUNREACH, but the guest check accepted only ENETUNREACH (51). On the same machine, which has no IPv6 address or route, the host sendto to ::1 failed with ENETUNREACH earlier in the day and with EADDRNOTAVAIL later (strace: sendto(..., inet_pton(AF_INET6, "::1", ...)) = -1 EADDRNOTAVAIL), with no change to the code in between. The guest then sees 49, the skip is not taken and Require(sent == sizeof(payload)) aborts.

The guest check now accepts the FreeBSD numbers of the same three errors the host probe accepts: 49, 51 and 65. Hosts with a usable ::1 still run every IPv6 check.

Same host condition as the merged #7847 (guest_datagram_*) and the closed #2820 (guest_sce_net), in a different test.

Tested

Ubuntu 26.04.1, kernel 7.0.0-38, GCC 15.2.0, Release, full build with BUILD_TESTING=ON.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

…ce_net

guest_sce_net skips its IPv6 checks when sending to ::1 fails and
HostIpv6LoopbackUnavailable confirms the host cannot reach it. The host
probe accepts EADDRNOTAVAIL, ENETUNREACH and EHOSTUNREACH, but the guest
check accepted only ENETUNREACH (51). On a Linux host without ::1 the
send can fail with EADDRNOTAVAIL instead, which the guest sees as 49,
and the test aborted in CheckUnspecifiedIpv6 instead of skipping.

Accept the guest numbers of the same three errors (49, 51 and 65).
@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 5836 core/libs/tests/GuestSceNet.cpp
PR 6044 core/libs/tests/GuestSceNet.cpp
PR 7332 core/libs/tests/GuestSceNet.cpp
PR 7959 core/libs/tests/GuestSceNet.cpp

@github-actions github-actions Bot added the fix error Closes an issue (Fixes #N) label Oct 19, 2026
@oneandonlydean
oneandonlydean merged commit 500cc64 into boykopovar:main Oct 20, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix error Closes an issue (Fixes #N)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

guest_sce_net aborts when IPv6 is disabled by sysctl (kernel has IPv6, ::1 unusable)

2 participants