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

Escaping really needed? #41

Open
ruppde opened this issue Jan 27, 2023 · 0 comments
Open

Escaping really needed? #41

ruppde opened this issue Jan 27, 2023 · 0 comments

Comments

@ruppde
Copy link
Contributor

ruppde commented Jan 27, 2023

is this really needed in yarGen.py? strings with double quotes end up with 5 backslashes when creating new json files with "-g -c", e.g.

             "\\\\\"isexe@": 1,

probably they get escaped a 2nd time by the json-export function?

            # Escape strings
            if len(string) > 0:
                string = string.replace(b'\\', b'\\\\')
                string = string.replace(b'"', b'\\"')

looks to me like it works without these 3 lines (which results in only one backslah before a doublequote) but I'm new to yarGen??

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

1 participant