-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix octetStringEscapedForCLiteral to handle non-ASCII better. (#13138)
There were several bugs in octetStringEscapedForCLiteral: 1. It used \x escapes, but decimal charcode numbers. Since it was only tested for charcode 0, this was not obvious. 2. It did not escape '"', which could break things. 3. It did not escape non-control non-ASCII characters (anything with charcode > 127). As a result the string "\r\n\xff\"\xa0" in YAML would get represented in the C++ as: "\x13\x10ÿ" " and after this change is represented as: "\x0d\x0a\xff\x22\xa0"
- Loading branch information
1 parent
7283e3a
commit 4867993
Showing
4 changed files
with
2,968 additions
and
2,843 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.