Skip to content
Snippets Groups Projects
Commit 2b0db997 authored by Petteri Aimonen's avatar Petteri Aimonen
Browse files

More backslash escape fixes

parent f313dee3
No related branches found
No related tags found
No related merge requests found
......@@ -18,11 +18,11 @@ Fix handling of string and bytes default values
-----------------------------------------------
**Rationale:** Previously nanopb didn't properly decode special character
escapes like \200 emitted by protoc. This caused these escapes to end up
escapes like \\200 emitted by protoc. This caused these escapes to end up
verbatim in the default values in .pb.c file.
**Changes:** Escapes are now decoded, and e.g. "\200" or "\x80" results in
{0x80} for bytes field and "\x80" for string field.
**Changes:** Escapes are now decoded, and e.g. "\\200" or "\\x80" results in
{0x80} for bytes field and "\\x80" for string field.
**Required actions:** If code has previously relied on '\\' in default value
being passed through verbatim, it must now be changed to '\\\\'.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment