mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-04-24 23:36:00 +03:00
[GH-ISSUE #2378] [APP BUG]: "Directory to Install Game Path doesn't handle characters with accents #804
Labels
No labels
Bloodborne
bug
contributor wanted
documentation
enhancement
frontend
good first issue
help wanted
linux
pull-request
question
release
verification progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/shadPS4#804
Loading…
Add table
Add a link
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?
Originally created by @Exo61 on GitHub (Feb 8, 2025).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/2378
Checklist
Describe the Bug
When installing ShadPS4 into a directory or path with a character containing an accent (like "É"), the path has to be re-added every time ShadPS4 is being launched.
The main reason is that it replaces the character with an accent by multiple symbols, corrupting the path and therefore not listing games anymore.
Here is a screenshot: https://ibb.co/27x4Stw4
Can you fix this issue?
Thank you
Reproduction Steps
Expected Behavior
Directory to Install Game Path remains the same everytime ShadPS4 is open, no matter the name of the folders
Specify OS Version
Windows 11
@KnifeOnlyI commented on GitHub (Feb 9, 2025):
Hello,
I am currently investigating the cause of the problem and can already conclude that it is not due to the saving of the path in the configuration file. In the config.toml file, the path is correctly stored with the accents. Therefore, it is probably the in-memory loading of the string that is causing the issue.
After reopen ShadPS4 :
The string in
config.tomlfile :If I use a debugger, this is what I get: the string loaded in memory doesn't handle the accents. It would be interesting to see if it's the same on Linux. (
src/common/config.cpp)@AfonsoMendoncaJacinto commented on GitHub (Feb 25, 2025):
If I understand this correctly, the solution would be to issue a warning in the frontend, if the desired path has accents?
@KnifeOnlyI commented on GitHub (Feb 25, 2025):
@AfonsoMendoncaJacinto Probably not. The toml file contains correct strings (with accents), we just need to read it correctly. Currently I think the problem come from the reading file operation, not writing.
I don't know the TOML library used by ShadPS4, I don't know if the problem come from this library or ShadPS4 code. I can't find any information about how TOML library read file and handle UTF-8.
@DoubleSpicy commented on GitHub (Feb 27, 2025):
Is it caused by incorrect encoding? characters like é are not supported by ASCII, so probably std::wstring is needed to support UTF-8.
@JoooPT commented on GitHub (Mar 7, 2025):
Can I get assigned to this? I would like to work on it.
@Hermiten commented on GitHub (Mar 29, 2025):
Fixed with #2699