fix(libSceWebBrowserDialog): permit termination from finished state in sceWebBrowserDialogTerminate #4509

Merged
ErenYeager1836 merged 1 commit from upstream-pr/4509 into main 2026-10-13 00:34:25 +00:00
ErenYeager1836 commented 2026-10-12 13:49:57 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ErenYeager1836 on 2026-10-12T13:49:57Z.


What

Permit sceWebBrowserDialogTerminate to terminate cleanly from COMMON_DIALOG_STATUS_FINISHED (3) in addition to COMMON_DIALOG_STATUS_INITIALIZED (1), aligning with libSceCdlgPlayerReview and other common dialogs.

Previously, sceWebBrowserDialogTerminate only accepted state 1 and threw std::logic_error if called after a dialog completed (sceWebBrowserDialogOpen transitions state to COMMON_DIALOG_STATUS_FINISHED).

Extended GuestWebBrowserDialog.cpp to cover:

  • Terminating from COMMON_DIALOG_STATUS_FINISHED state back to COMMON_DIALOG_STATUS_NONE.
  • Uninitialized and null-parameter checks for sceWebBrowserDialogClose and sceWebBrowserDialogGetResult.

Tested

  • Windows 11 (x86_64 MinGW GCC 15 / Ninja).
  • Unit tests: guest_web_browser_dialog_tests passed (ctest -R guest_web_browser_dialog -> 100% passed in 0.04 s).
  • Conventions: python tools/check_conventions.py --base upstream/main passed with 0 errors.

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 in TechnicalDebt
  • 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
  • Unblocks: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4830361582 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/4509). Originally posted by [ErenYeager1836](https://github.com/ErenYeager1836) on 2026-10-12T13:49:57Z. --- ### What Permit `sceWebBrowserDialogTerminate` to terminate cleanly from `COMMON_DIALOG_STATUS_FINISHED` (3) in addition to `COMMON_DIALOG_STATUS_INITIALIZED` (1), aligning with `libSceCdlgPlayerReview` and other common dialogs. Previously, `sceWebBrowserDialogTerminate` only accepted state 1 and threw `std::logic_error` if called after a dialog completed (`sceWebBrowserDialogOpen` transitions state to `COMMON_DIALOG_STATUS_FINISHED`). Extended `GuestWebBrowserDialog.cpp` to cover: - Terminating from `COMMON_DIALOG_STATUS_FINISHED` state back to `COMMON_DIALOG_STATUS_NONE`. - Uninitialized and null-parameter checks for `sceWebBrowserDialogClose` and `sceWebBrowserDialogGetResult`. ### Tested - Windows 11 (x86_64 MinGW GCC 15 / Ninja). - Unit tests: `guest_web_browser_dialog_tests` passed (`ctest -R guest_web_browser_dialog` -> 100% passed in 0.04 s). - Conventions: `python tools/check_conventions.py --base upstream/main` passed with 0 errors. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed in [TechnicalDebt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/TechnicalDebt.md#silent-stubs) - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Unblocks: none - [x] AI-assisted: yes
overlordxrz-source commented 2026-10-12 18:41:58 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by overlordxrz-source on 2026-10-12T18:41:58Z.


Title confirmation: Nuvio PS5 (PPSA99997) hits this. On Linux (Ubuntu 24.04, lavapipe), main b538b28d8 + #4470 renders and presents 4 frames, closes its browser session, then aborts with what(): sceWebBrowserDialogTerminate: not initialized or still running. With this PR added, it gets past that and runs for 120 s with no stop.

AI-assisted: yes

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6130415354 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/4509#issuecomment-6130415354). Originally posted by [overlordxrz-source](https://github.com/overlordxrz-source) on 2026-10-12T18:41:58Z. --- Title confirmation: Nuvio PS5 (PPSA99997) hits this. On Linux (Ubuntu 24.04, lavapipe), main b538b28d8 + #4470 renders and presents 4 frames, closes its browser session, then aborts with `what(): sceWebBrowserDialogTerminate: not initialized or still running`. With this PR added, it gets past that and runs for 120 s with no stop. AI-assisted: yes
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!4509
No description provided.