test(libSceRtc): cover null pointer validation in current tick getters #12222
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/12222"
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 al3w0f205 on 2026-10-28T03:51:50Z.
What
Add test coverage in
GuestRtc.cppfor null pointer validation in current tick getters:nullptrtick pointer insceRtcGetCurrentTickwithinvalidPointernullptrtick pointer insceRtcGetCurrentNetworkTickwithinvalidPointernullptrtick pointer insceRtcGetCurrentRawNetworkTickwithinvalidPointernullptrtick pointer insceRtcGetCurrentAdNetworkTickwithinvalidPointernullptrtick pointer insceRtcGetCurrentDebugNetworkTickwithinvalidPointerTested
python tools/check_conventions.py --base origin/main(all conventions checks passed) andgit diff --check(clean).ctest -R guest_rtc(1/1 test passed, 0 failures).Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-28T04:12:59Z.
Review: CHANGES_REQUESTED
The five added null-output checks match the current implementations, each of which returns
SCE_RTC_ERROR_INVALID_POINTERbefore dereferencing the output. I built the exact changed test source and ranguest_rtc; it passed 1/1 in the isolated review build with only the unrelated host CPU startup gate bypassed. The ordinary host run cannot reach assertions on this Xeon. Hosted Windows passed, the rerun of Conventions passed, and Linux was skipped by CI.Please update the branch to current
mainand rerun affected checks, as required by CONTRIBUTING. It is 42 commits behind7fe69e276fc4e000ccb2a360ea8faeb3d7fcc137; intervening main changes do not touchGuestRtc.cpp, and the merge preview is clean. The PR body also omits the required third-party-submodule checklist line and gives only platform checkboxes rather than the OS, focused command and result. Please restore every template line and record the test details before approval. I found no functional issue in these assertions.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-28T04:44:05Z.
Review: CHANGES_REQUESTED
The Windows job successfully linked the changed host-only test executable, but the test-selection and CTest steps were skipped. The description reports only conventions and
git diff --check; it does not report running the new null-output assertions. Please run the focused RTC test on this head and add the exact command/result before approval. I checked currentExport.cpp; all five getters return the same invalid-pointer code for null output.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T06:43:00Z.
Review: APPROVED
Re-reviewed — approved
I reviewed exact head
994049e8bf8203b32e01e6ae299229b8c8f61abfagainst currentmain2960e9a6e7e1fc99c4ed180c71495b5eb83464c7.What I ran
GuestRtc.cppand checked that currentmainhas no later change to that file since the PR's base.git merge-tree --write-tree refs/remotes/upstream/main refs/review/upstream-12222; clean tree429aeb5f6f77e786b08a7587aee9d072296c1775.git diff --check refs/remotes/upstream/main...refs/review/upstream-12222; exit 0, no output.Results
ctest -R guest_rtcpassed 1/1 on Windows 11Negative control
This test-only change has no separate negative control reported. I did not run one locally.
Findings
Blocking
None. The updated
Testedsection now records the focused command and result requested in my previous review, and the assertions match the null-output checks in all five getters.Non-blocking
I did not independently execute the RTC test; the focused result is author-reported.
Sources
Not verified
I did not independently build or run CTest. The focused 1/1 result and Windows environment are author-reported.