mirror of https://github.com/python/cpython.git
GH-131296: Avoid invalid signed char comparison in getpath.c assertion (GH-131594)
This commit is contained in:
parent
79f7c67bf6
commit
f663b2c56a
|
@ -690,7 +690,7 @@ env_to_dict(PyObject *dict, const char *key, int and_clear)
|
|||
// Quick convert to wchar_t, since we know key is ASCII
|
||||
wchar_t *wp = wkey;
|
||||
for (const char *p = &key[4]; *p; ++p) {
|
||||
assert(*p < 128);
|
||||
assert(!(*p & 0x80));
|
||||
*wp++ = *p;
|
||||
}
|
||||
*wp = L'\0';
|
||||
|
|
Loading…
Reference in New Issue