summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2013-07-20 12:57:28 (GMT)
committerChristian Heimes <christian@cheimes.de>2013-07-20 12:57:28 (GMT)
commitb578735dffb37b6671473e206d5339a885367126 (patch)
treebdeafeb961d3f4c0cab3cbdc7173372aa7b37ae7
parent74ba26a40c3f7bed538aa9ab12db28da82a45685 (diff)
parent26532f7519b9b7764dd046acab49d5fc5dbcd94d (diff)
downloadcpython-b578735dffb37b6671473e206d5339a885367126.zip
cpython-b578735dffb37b6671473e206d5339a885367126.tar.gz
cpython-b578735dffb37b6671473e206d5339a885367126.tar.bz2
Check return value of PyType_Ready(&EncodingMapType)
CID 486654
-rw-r--r--Objects/unicodeobject.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index 8ce3f96..37fb964 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -14578,7 +14578,8 @@ int _PyUnicode_Init(void)
PyUnicode_2BYTE_KIND, linebreak,
Py_ARRAY_LENGTH(linebreak));
- PyType_Ready(&EncodingMapType);
+ if (PyType_Ready(&EncodingMapType) < 0)
+ Py_FatalError("Can't initialize encoding map type");
if (PyType_Ready(&PyFieldNameIter_Type) < 0)
Py_FatalError("Can't initialize field name iterator type");