Merged revisions 82157 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/trunk

........
  r82157 | benjamin.peterson | 2010-06-22 14:16:37 -0500 (Tue, 22 Jun 2010) | 1 line

  remove INT_MAX assertions; they can fail with large Py_ssize_t #9058
........
This commit is contained in:
Benjamin Peterson 2010-06-22 19:21:52 +00:00
parent 0fdbd97d5e
commit 285a689c8f
2 changed files with 2 additions and 3 deletions

View File

@ -37,6 +37,8 @@ Core and Builtins
- Issue #8969: On Windows, use mbcs codec in strict mode to encode and decode
filenames and enable os.fsencode().
- Issue #9058: Remove assertions about INT_MAX in UnicodeDecodeError.
- Issue #8941: decoding big endian UTF-32 data in UCS-2 builds could crash
the interpreter with characters outside the Basic Multilingual Plane
(higher than 0x10000).

View File

@ -1622,9 +1622,6 @@ PyUnicodeDecodeError_Create(
const char *encoding, const char *object, Py_ssize_t length,
Py_ssize_t start, Py_ssize_t end, const char *reason)
{
assert(length < INT_MAX);
assert(start < INT_MAX);
assert(end < INT_MAX);
return PyObject_CallFunction(PyExc_UnicodeDecodeError, "sy#nns",
encoding, object, length, start, end, reason);
}