libkernel: poll throws 'descriptor 3 is not a socket' for a pipe descriptor (ProsperoTV) #3584
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by reyani-dev on 2026-10-11T13:46:01Z.
ProsperoTV (PPSA99003) stops right after its menu opens, on
maina11c8f7f(Windows 11, RTX 4070, catalog build witheboot.binandsce_module/libc.prxunwrapped):The title writes this to its own log (
download0/profiles/10000000/logs/app.log). The console shows only the entry-point line and exit0xc0000409.poll(Socket/src/Udp.cpp:868) accepts only socket descriptors (>= GuestSockets::FirstDescriptor,0x10000000) and throws for anything else. Descriptor 3 here comes frompipe:pipe(File/src/Stdio.cpp:380) returns the host C-runtime descriptors from_pipe/pipe, which start at 3;pipeonce, next tosocketpair,select, andpoll(9 call sites);poll, so it comes from a library linked into the title. A wakeup pipe polled together with sockets (as curl's multi interface does) fits.On FreeBSD,
pollon a pipe reportsPOLLINwhen data is buffered or the write end is closed (POLLHUP), andPOLLOUTwhen there is room. Supporting this meanspollhas to wait on a mix of socket and pipe descriptors with one timeout. On Linux the host descriptors can go to the nativepollas they are. On Windows, CRT pipes can't be waited on withWSAPoll, so it needs another readiness check (for examplePeekNamedPipeon the read end) or a different pipe implementation.Found with Claude Code.
Imported from boykopovar/AnyPS5. Originally posted by reyani-dev on 2026-10-11T14:45:21Z.
A second title reaches this: ProsperoLichess (PPSA99009), once its two earlier stops are fixed (mspace alignment, #3639, then
kern.arandom):(Its own log,
download0/prosperolichess/app.log, Windows 11, onmaina11c8f7fplus those two changes.)Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-12T06:17:42Z.
Closing as a duplicate of #3521: same throw,
poll: descriptor N is not a socket(Socket/src/Udp.cpp:907). #3649 and #3644 both fix it; whichever merges covers PPSA99009 too.