Commit graph

711 commits

Author SHA1 Message Date
Henrik Rydgård
b7f0a9029e More cleanup 2024-04-07 12:36:32 +02:00
Henrik Rydgård
79c553d004 Remove the zero-write in BuildHash 2024-04-07 12:31:45 +02:00
Henrik Rydgård
404600faa3 SavedataParam/ParamSFO: Minor code cleanups 2024-04-07 12:31:45 +02:00
Henrik Rydgård
77133dd82c Fix a long-standing buffer overflow in savedata encryption
BuildHash pads the buffer up to its 16-byte aligned size with zeroes,
so there needs to be space for that. Or, we should just remove that
write, but let's do the smallest change that fixes the bug for now.
2024-04-07 11:42:51 +02:00
Herman Semenov
17ecee1715 Fixed return copies from functions and const ref params 2024-04-02 18:37:00 +03:00
Bobby Smith
133e9e37ae Crash fix for some games 2024-02-23 01:37:07 +01:00
Henrik Rydgård
c5791764d8 Make the i18n T function use std::string_view
Buildfixes, crashfixes

One more

Android buildfix

Buildfix Qt
2024-02-12 18:44:39 +01:00
Henrik Rydgård
1304d04161 Fix a particular type of race condition in file dialog requests
It seems to be possible for a user to back out of a screen before
receiving the "dialog completed" callback on Android, in which case
things pointed to by the callback might be gone.

In this case, it's better to simply not call the callback, rather than
crashing.

This is accomplished by assigning "Tokens" to screens that cause
requests, and in ~Screen, invalidate any pending requests belonging to
that token.
2024-01-18 12:25:55 +01:00
Henrik Rydgård
e3177ac870 Make some global string pointers const, not just the strings.
Minor cleanup.
2023-12-29 14:09:45 +01:00
Herman Semenov
2a31f8c6c0 [Common/Core/HLE] Object out of scope optimization for better codegeneration (lower level scope) 2023-12-20 12:33:56 +03:00
Herman Semenov
b871e76d05 [Core/Debugger/FileLoaders/FileSystems/MIPS] Using reserve if possible 2023-12-15 13:59:19 +03:00
Henrik Rydgård
ebaebf5945
Merge pull request #18546 from GermanAizek/make-smart-ptr
[Common Data/Core Dialog HLE/GPU Common Vulkan] Optimize create smart pointers using C++17 std::make_*
2023-12-14 14:02:55 +01:00
Henrik Rydgård
b78c7ad470
Merge pull request #18545 from GermanAizek/const-ref-params
Objects in function parameters have been replaced with constant references
2023-12-14 13:49:33 +01:00
Herman Semenov
08070e7f31 [Common Data/Core Dialog HLE/GPU Common Vulkan] Optimize create smart pointer using C++17 std::make_* 2023-12-14 15:44:16 +03:00
Herman Semenov
af41281761 [Core/Dialog/ELF/FileSystems/HLE/HW/Util] Added const reference for function params 2023-12-14 14:22:24 +03:00
Herman Semenov
315340fc62 Using const reference for C++17 range-based loop and freq used objects 2023-12-13 17:33:01 +01:00
Katharine Chui
652498e995 Handle SCE_UTILITY_SAVEDATA_TYPE_SAVE then SCE_UTILITY_SAVEDATA_TYPE_WRITEDATA
Modnation racers does a normal save for global profile, then
writes an insecure file for keeping track of selected language.
During SCE_UTILITY_SAVEDATA_TYPE_WRITEDATA it also provides no
data for param.sfo, so I'm assuming that utility.prx does not
update param.sfo data in that mode since the PSP save provided on
the issue tracker has information.
2023-11-18 03:48:01 +08:00
Henrik Rydgård
3d0051f34b Fix enabling of native keyboard input on Switch 2023-08-30 18:14:17 +02:00
Henrik Rydgård
1cf2a161a0 Replace the notifications with a bare-bones progress bar 2023-08-17 14:42:25 +02:00
sum2012
e00a41702c Add GamedataInstall of osm
fix #14688
2023-08-17 14:22:30 +02:00
Henrik Rydgård
eb14c87a71 Allow configuring the game language separately from the PPSSPP UI language, with a new setting. 2023-07-23 11:30:04 +02:00
Henrik Rydgård
eb21a2e6c9 Break out the OSD data holder from Common/System/System.h, into OSD.cpp/h 2023-06-30 17:15:49 +02:00
Henrik Rydgård
7cc8c6cea4 OSD: Add semantics, move the the OSD state to common (while keeping the renderer in the UI). 2023-06-20 14:40:46 +02:00
Unknown W. Brackets
c122ee0a11 HLE: Add some assorted detected func names.
These come from here:
https://github.com/SiSTR0/sce_symbols/blob/main/psp_names.txt
2023-06-06 23:50:49 -07:00
Henrik Rydgård
4a2a9830a6 PSPOskDialog: Add sanity check.
Also shrinks some arrays.

Fixes #17313

(We really should somehow get rid of marking this file as binary in
.gitattributes).
2023-04-21 09:12:06 +02:00
Henrik Rydgård
ee6234ecb6 I18N: Switch to getting categories by index instead of by string lookup
Also gets rid of the shared_ptr usage, and generally makes things nicer.

Needed for later config refactorings, good to get in early.
2023-04-07 10:35:01 +02:00
Henrik Rydgård
221d2f7eb5 RequestManager: Add a separate callback for failures. Separate because we usually don't need it, except Osk. 2023-03-25 18:49:23 +01:00
Henrik Rydgård
9e125eeba7 Remove NotifyUserMessage from Host 2023-03-25 10:32:09 +01:00
Henrik Rydgård
de064e210e Replace the inputbox queue with a more generic RequestManager. 2023-03-22 12:41:11 +01:00
Unknown W. Brackets
0532b35538 Osk: Update by button flag consistently. 2023-02-12 10:06:53 -08:00
Unknown W. Brackets
d7732f7fd7 Dialog: Warn when ignoring the dialog language. 2023-02-08 19:04:18 -08:00
Unknown W. Brackets
fcc1abc7c3 Dialog: Update by button flag consistently.
Always check for the flag to change in Update().
2023-02-08 19:02:37 -08:00
Unknown W. Brackets
dea9cac16c Core: Add range checks to some helpers and similar. 2023-01-09 16:56:18 -08:00
Henrik Rydgård
7e374c9324 Address feedback, more fixes 2023-01-05 08:38:53 +01:00
Henrik Rydgård
fd7cc76d95 Remove unnecessary savedata version reporting 2023-01-02 23:22:54 +01:00
Unknown W. Brackets
87172f9dd5 Dialog: Fix confirm/cancel button reversal. 2023-01-01 09:34:13 -08:00
Henrik Rydgård
61cc6cd0e0 Fix bug swapping O/X visually on PSPOskDialog 2022-12-16 21:51:20 +01:00
Unknown W. Brackets
a7b7bf7826 Global: Set many read-only params as const.
This makes what they do and which args to use clearer, if nothing else.
2022-12-10 21:13:36 -08:00
Unknown W. Brackets
f44852bb18 Global: Cleanup virtual/override specifiers.
Also missing virtual destructors, hidden non-overrides, etc.
2022-12-10 21:13:36 -08:00
Henrik Rydgård
93e5060137 Load and cache langValuesMapping on demand 2022-12-05 12:10:45 +01:00
Henrik Rydgård
f954013d0b Fix (?) the savestate bug in PSPSaveDialog/SaveDataParam
PSPSaveDialog::DoState called SetPspParam in non-READ modes, which could
modify it.
2022-12-02 22:46:39 +01:00
Henrik Rydgård
f5a7661c51 Add a NOOP state to reduce logspam after error 2022-12-02 22:46:38 +01:00
Henrik Rydgård
5b3a993db7 Typo fix 2022-11-28 09:50:23 +01:00
Henrik Rydgård
21647cd3c1 Blind workaround for Shining Ark circle button problem
Seems the game might not handle the case of confirm button being set to
cross properly, so force it to circle if this game is running.

Fixes #15663 (hopefully..)
2022-11-27 23:32:43 +01:00
Unknown W. Brackets
29e7a53b5d Savedata: Update filelist on file erasure.
Also stop reporting as "not coded."
2022-10-16 09:20:04 -07:00
Unknown W. Brackets
db5011d7f1 Savedata: Cache SFO data during processing.
This only caches between touching PSP code, in case something changes.
Reduces cases of multiple SFO lookups and reads.
2022-10-09 14:42:31 -07:00
Unknown W. Brackets
5bed35b293 Savedata: Skip and defer texture exist check.
We can skip if there's no UI.
2022-10-09 14:42:31 -07:00
Unknown W. Brackets
8c1acc30e4 Savedata: Combine file info and dir listing calls. 2022-10-09 14:42:31 -07:00
Unknown W. Brackets
6168e03b4a Savedata: Reduce some duplicate file info lookups. 2022-10-09 14:42:31 -07:00
Unknown W. Brackets
d473aa6db0 Module: Cleanup file read pattern.
Let's always use ReadEntireFile() when we can.
2022-10-09 14:42:30 -07:00