libSceSharePlay: sceSharePlayGetCurrentConnectionInfoA (RE4) with the layout and error code from KytyPS5 and fpPS4; branch ready #3210
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 Silverash-i8 on 2026-10-11T01:27:05Z.
Follow-up to #3144, which closed with the SystemGesture half (#3174). The SharePlay half was left out because its result was a guess with no reference. There are two references now, and they agree, so here is that half again with the layout and error code filled in.
Title: RE4 (PPSA07411) stops on
sceSharePlayGetCurrentConnectionInfoA, whichmaindoesn't export (xXPBSXx's report in #3144).References
libNet.cpp:SharePlayConnectionInfoAisstatus,mode, two 20-byte online IDs, two 64-bit account IDs and two user IDs, withstatic_asserts for size 72,host_account_idat 48 andhost_user_idat 64. A null pointer returnsSHARE_PLAY_ERROR_INVALID_ARGS(-2129788927, 0x810E0001); otherwise it writes status 0 and both user IDs -1.ps4_libsceshareplay.pas: the same fields in the same order,SCE_SHARE_PLAY_ERROR_INVALID_ARGS = 0x810E0001, DORMANT = 0, INVALID_ARGS for null and a zeroed struct otherwise.Branch:
Silverash-i8/AnyPS5-fork:fix/shareplay-connection-info-layout, onmain06da1176: xXPBSXx's691b0d50(their authorship kept) plus027ebf97.SharePlayConnectionInfoAinSceTypes.hppnext toNpOnlineId, with the size and offset asserts.SCE_USER_SERVICE_USER_ID_INVALID, as KytyPS5 does). Null returns 0x810E0001.sceSharePlayInitialize, which this library keeps no state for.guest_share_playfills the struct with 0x5a first, checks every field, and checks the null case.Tested on Windows 11, WinLibs GCC 15.2.0 r7, Release:
guest_share_playandpatched_librariespass, andtools/check_conventions.py --base upstream/mainpasses. I don't have RE4. xXPBSXx's run in #3144 showed the title stops on the missing export and runs past the call once it exists; xXPBSXx then ran RE4 with this branch (comment): it no longer stops onsceSharePlayGetCurrentConnectionInfoAand continues to the next, unrelated stop (scan conversion mode is unsupported (register 0x292 = 0x00000003), #2776), with no SharePlay output in the log. What the title does with the struct beyond that wasn't examined.AI-assisted (Claude Code); I read both sources and ran the tests on my machine.
Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-11T06:53:02Z.
@Silverash-i8 thank you, this is better than my version: mine only returned 0 and wrote nothing, with no reference behind it (I said that in the TechnicalDebt entry), and yours has the layout, the error code and two sources that agree. Please treat your branch as the one to carry and mine (
fix/shareplay-connection-info) as superseded.One correction to the wording above: "the in-title check is xXPBSXx's from #3144" is more than I measured. On RE4 I only saw that the title stopped on the missing export and that it ran past the call once the export existed. I did not check what it does with the struct afterwards (it reads a field at offset 0x40 of its own stack structure, which I could not tie to this call). I can rerun RE4 with your branch and report whether it still gets past that point; I will do that in the next session with the title and post the result here.
AI-assisted (Claude Code).
Imported from boykopovar/AnyPS5. Originally posted by Silverash-i8 on 2026-10-11T06:53:41Z.
@xXPBSXx thanks, and you're right, I overstated it. I've changed the issue text to say only what you measured: RE4 stops on the missing export and runs past the call once it exists, and what it does with the struct isn't checked yet.
On the read at offset 0x40: in the layout KytyPS5 asserts (
static_assert(offsetof(SharePlayConnectionInfoA, host_user_id) == 64)), 0x40 ishostUserId, which this branch sets to -1 and your version left as whatever the stack held. If that stack structure turns out to be the info buffer RE4 passes to the call, your rerun would show directly whether it's happy with -1 there. That's only a guess from the offset, though.AI-assisted (Claude Code).
Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-11T07:02:19Z.
RE4 (PPSA07411) result with your
fix/shareplay-connection-info-layout(027ebf97) merged into a local test branch with my other branches (currentmain06da1176, the library-skip branch from #2591, my RE4 export stubs): the import audit shows 0 absent imports, and the title no longer stops onsceSharePlayGetCurrentConnectionInfoA. In a 100 s run it goes on to the video-out check I described on #2776 (scan conversion mode is unsupported (register 0x292 = 0x00000003)), so it gets past the SharePlay call, and I saw no SharePlay-related output in the log. I did not examine what the title does with the returned struct beyond that.One thing to know when this is carried together with my RE4 export branch:
guest_ppsa07411_exportsthere still listssceSharePlayGetCurrentConnectionInfoAas an export that throws, so that list needs the entry removed once your implementation is in (it failed for me on the combined branch for that reason). That test is not onmain.AI-assisted (Claude Code).
Imported from boykopovar/AnyPS5. Originally posted by reyani-dev on 2026-10-11T08:14:27Z.
Carried as #3341 with both commits unchanged (@xXPBSXx's export and @Silverash-i8's layout). On Windows 11 / GCC 15.2,
guest_share_playpasses 3/3 and doesn't link without the export; the CPU suite passes 428/428.