Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GameFinder fails to parse Steam Manifest if there is a quotation mark used in a drive label #127

Open
2KDrop opened this issue Feb 16, 2024 · 1 comment

Comments

@2KDrop
Copy link

2KDrop commented Feb 16, 2024

As title says, when a drive for a Steam library is labelled with a " in the name, such as Game Drive 3.5" it will fail to parse the file.

Renaming the drive in the Steam drive menu to not include the " solves the issue as a bandaid solution

Example from the libraryfolders.vdf file

	"path"		"F:\\Games\\Steam"
	"label"		"Game Drive 3.5\""
	"contentid"		"2288888475556474100"
	"totalsize"		"1000191553536"

Renaming the drive in steam to no longer include the " turns it to this

	"path"		"F:\\Games\\Steam"
	"label"		"Game Drive 3.5"
	"contentid"		"2288888475556474100"
	"totalsize"		"1000191553536"

Which can be read no issue

@2KDrop 2KDrop changed the title Game finder fails to parse Steam Manifest if there is a quotation mark used in a drive label GameFinder fails to parse Steam Manifest if there is a quotation mark used in a drive label Feb 16, 2024
@Nutzzz
Copy link
Contributor

Nutzzz commented Mar 11, 2024

It looks like this is an issue with ValveKeyValue, which GameFinder uses to deserialize Steam's various files. Steam can apparently be a little wonky in its handling of escape sequences, and ValveKeyValue attempts to faithfully reproduce the wonkiness. Note if the quotation marks are matched (i.e., there is an even number of them), the exception does not occur.

@erri120 : It's kind of a workaround, but if I add a KVSerializerOptions with "{ HasEscapeSequences = true }" on the .Deserialize() call on line 38 of LibraryFoldersManifestParser, then the exception doesn't happen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants