Emulator Issues #9391
openController Profile naming doesn't filter out characters with special meanings
0%
Description
Open up the Emulated Wiimote config window, type a relative filepath into the Profile box, and hit Save. The window will save the profile, but can't find the created file so it looks like it just disappears.
Examples:
Type "a/b" and hit Save. Profile gets saved as "[userdir]\Config\Profiles\Wiimote\a\b.ini", creating the "a" directory, but the file is not displayed in the dropdown.
Type "../../Dolphin" and hit Save. Profile gets saved as "[userdir]\Config\Dolphin.ini", overwriting the main Dolphin config file.
I recommend just disallowing paths.
On this note, typing a name that has characters that are illegal in the filesystem doesn't save anything but doesn't display an error either.
Updated by JosJuice over 6 years ago
- Has duplicate Emulator Issues #11258: Qt/MappingWindow: Controller profile names containing asterisks cause problems added
Updated by JosJuice over 6 years ago
- Subject changed from Controller Profile selection allows relative file paths. to Controller Profile naming doesn't filter out characters with special meanings
Updated by Billiard26 almost 6 years ago
- Assignee set to Billiard26
The only thing stopping me from implementing this is deciding on which special characters to disallow.
"Special" is OS-specific.
Updated by AdmiralCurtiss almost 6 years ago
The alternative, which might be a bit more safe in general, would be to disconnect the name of the profile and the name of the file on disk. Just name the files something generic and place the actual name within the file. Dunno if that can be done in a backwards-compatible way though.
Updated by Billiard26 almost 6 years ago
Yeah. That could be done and backwards compatibility would be feasible.