diff options
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/bytesobject.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Objects/bytesobject.c b/Objects/bytesobject.c index ef3a5a1..c0f5aff 100644 --- a/Objects/bytesobject.c +++ b/Objects/bytesobject.c @@ -484,6 +484,10 @@ PyObject *PyBytes_DecodeEscape(const char *s, errors); goto failed; } + /* skip \x */ + if (s < end && Py_ISXDIGIT(s[0])) + s++; /* and a hexdigit */ + break; default: *p++ = '\\'; s--; |