Differences From Artifact [08913e2453]:
- File
src/OFString+JSONParsing.m
— part of check-in
[6fbc3b18c7]
at
2024-10-27 22:27:20
on branch trunk
— Allow strings to contain \0
In order to not accidentally have C strings with \0, an
OFInvalidEncodingException is thrown when trying to get a C string for a
string that contains \0.In order to get a C string with \0 anyway, a new method
-[insecureCStringWithEncoding:] is added. (user: js, size: 13386) [annotate] [blame] [check-ins using]
To Artifact [14e3ab6458]:
- File src/OFString+JSONParsing.m — part of check-in [d7bbf983f0] at 2024-10-27 23:48:14 on branch trunk — Allow \u0000 in JSON (user: js, size: 13353) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
133 134 135 136 137 138 139 | ret |= c + 10 - 'a'; else if (c >= 'A' && c <= 'F') ret |= c + 10 - 'A'; else return 0xFFFF; } | < < < | 133 134 135 136 137 138 139 140 141 142 143 144 145 146 | ret |= c + 10 - 'a'; else if (c >= 'A' && c <= 'F') ret |= c + 10 - 'A'; else return 0xFFFF; } return ret; } static inline OFString * parseString(const char **pointer, const char *stop, size_t *line) { char *buffer; |
︙ | ︙ |