mirror of https://github.com/python/cpython
Set startinpos before calling the error handler.
This commit is contained in:
parent
a651d3de00
commit
2b65c75988
|
@ -1507,6 +1507,7 @@ PyObject *PyUnicode_DecodeUTF7(const char *s,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (SPECIAL(ch,0,0)) {
|
else if (SPECIAL(ch,0,0)) {
|
||||||
|
startinpos = s-starts;
|
||||||
errmsg = "unexpected special character";
|
errmsg = "unexpected special character";
|
||||||
s++;
|
s++;
|
||||||
goto utf7Error;
|
goto utf7Error;
|
||||||
|
|
Loading…
Reference in New Issue