fix(libSceAppContent): report no download space for a title without download data #1121

Closed
TideOPL wants to merge 1 commit from upstream-pr/1121 into main
TideOPL commented 2026-10-07 13:13:52 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TideOPL on 2026-10-07T13:13:52Z.


What

sceAppContentDownloadDataGetAvailableSpaceKb threw when the title's param.json declares a downloadDataSize of 0. PPSA16064 (Minecraft Dungeons II, Unreal Engine) declares 0 and still queries the space at start-up, and aborted there.

With a quota of 0 the existing computation already gives 0 KB available, so the guard is removed and the call returns 0 KB.

Tested

  • Windows 11, NVIDIA GeForce RTX 5070, MinGW-w64 GCC 15.2.0 (WinLibs UCRT r7). Full ctest: 393/393.
  • No new test: there's no existing harness for this call, and it would need a fake param.json.
  • PPSA16064: the title continues past the query.

Asking for ideas

I don't know whether the console returns 0 KB or an error for a title without download data; TechnicalDebt records it. If anyone has seen a title handle the other case, I'll change it.

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
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4773170556 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1121). Originally posted by [TideOPL](https://github.com/TideOPL) on 2026-10-07T13:13:52Z. --- ### What `sceAppContentDownloadDataGetAvailableSpaceKb` threw when the title's `param.json` declares a `downloadDataSize` of 0. PPSA16064 (Minecraft Dungeons II, Unreal Engine) declares 0 and still queries the space at start-up, and aborted there. With a quota of 0 the existing computation already gives 0 KB available, so the guard is removed and the call returns 0 KB. ### Tested - Windows 11, NVIDIA GeForce RTX 5070, MinGW-w64 GCC 15.2.0 (WinLibs UCRT r7). Full `ctest`: 393/393. - No new test: there's no existing harness for this call, and it would need a fake `param.json`. - PPSA16064: the title continues past the query. ### Asking for ideas I don't know whether the console returns 0 KB or an error for a title without download data; TechnicalDebt records it. If anyone has seen a title handle the other case, I'll change it. ### 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] AI-assisted: yes
merwie commented 2026-10-07 19:07:36 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by merwie on 2026-10-07T19:07:36Z.


Hi @TideOPL, #842 (opened 2026-10-06) makes the same change to sceAppContentDownloadDataGetAvailableSpaceKb, and a reviewer asked us to agree which one goes forward. #842 now also has the TechnicalDebt line and a ctest case (downloadDataSize 0 → OK with 0 KB). Would you be OK with #842 going forward and closing this one, or listing it under Depends on? Happy to credit your PPSA16064 evidence in its description. If you'd rather keep yours, I'm fine closing mine instead.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6044899861 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1121#issuecomment-6044899861). Originally posted by [merwie](https://github.com/merwie) on 2026-10-07T19:07:36Z. --- Hi @TideOPL, #842 (opened 2026-10-06) makes the same change to `sceAppContentDownloadDataGetAvailableSpaceKb`, and a reviewer asked us to agree which one goes forward. #842 now also has the TechnicalDebt line and a ctest case (`downloadDataSize` 0 → OK with 0 KB). Would you be OK with #842 going forward and closing this one, or listing it under **Depends on**? Happy to credit your PPSA16064 evidence in its description. If you'd rather keep yours, I'm fine closing mine instead.
TideOPL commented 2026-10-07 19:22:38 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TideOPL on 2026-10-07T19:22:38Z.


@merwie Go ahead and use your one! I'll go ahead and close this. Many thanks

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6045162508 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1121#issuecomment-6045162508). Originally posted by [TideOPL](https://github.com/TideOPL) on 2026-10-07T19:22:38Z. --- @merwie Go ahead and use your one! I'll go ahead and close this. Many thanks
TideOPL commented 2026-10-07 19:23:05 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by TideOPL on 2026-10-07T19:23:05Z.


Closed

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6045169745 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/1121#issuecomment-6045169745). Originally posted by [TideOPL](https://github.com/TideOPL) on 2026-10-07T19:23:05Z. --- Closed

Pull request closed

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!1121
No description provided.