mirror of
https://github.com/python/cpython.git
synced 2025-11-13 15:40:05 +00:00
load_string(): Force use of unsigned compare in a context that was
clearly (but incorrectly) assuming it.
This commit is contained in:
parent
f8197d4f9f
commit
bf5ca65c2d
1 changed files with 8 additions and 6 deletions
|
|
@ -2822,11 +2822,13 @@ load_string(Unpicklerobject *self) {
|
||||||
if (*p=='\\') nslash++;
|
if (*p=='\\') nslash++;
|
||||||
else nslash=0;
|
else nslash=0;
|
||||||
}
|
}
|
||||||
if (*p==q)
|
if (*p == q) {
|
||||||
{
|
for (p++; *p; p++)
|
||||||
for (p++; *p; p++) if (*p > ' ') goto insecure;
|
if (*(unsigned char *)p > ' ')
|
||||||
|
goto insecure;
|
||||||
}
|
}
|
||||||
else goto insecure;
|
else
|
||||||
|
goto insecure;
|
||||||
/********************************************/
|
/********************************************/
|
||||||
|
|
||||||
UNLESS (eval_dict)
|
UNLESS (eval_dict)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue