Commit dc6f5ef
committed
Copy potential BOM to the output of PyString_FromString
The documentation of the used `PyUnicode_DecodeUTF16` states that not
passing `*byteorder` or passing a 0 results in the first two bytes, if
they are the BOM (U+FEFF, zero-width no-break space), to be interpreted
and skipped, which is incorrect when we convert a known "non BOM"
string, which all strings from C# are.1 parent 4c46c6d commit dc6f5ef
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1252 | 1252 | | |
1253 | 1253 | | |
1254 | 1254 | | |
| 1255 | + | |
| 1256 | + | |
1255 | 1257 | | |
1256 | 1258 | | |
1257 | 1259 | | |
1258 | 1260 | | |
1259 | 1261 | | |
1260 | | - | |
| 1262 | + | |
1261 | 1263 | | |
1262 | 1264 | | |
1263 | 1265 | | |
| |||
0 commit comments