summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Misc/ACKS1
-rw-r--r--Objects/typeobject.c5
2 files changed, 6 insertions, 0 deletions
diff --git a/Misc/ACKS b/Misc/ACKS
index c7da1b0..fb64941 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -336,6 +336,7 @@ Oscar Nierstrasz
Hrvoje Niksic
Bill Noon
Stefan Norberg
+Tim Northover
Joe Norton
Neal Norwitz
Jeffrey Ollie
diff --git a/Objects/typeobject.c b/Objects/typeobject.c
index 0051179..7918af0 100644
--- a/Objects/typeobject.c
+++ b/Objects/typeobject.c
@@ -742,6 +742,11 @@ mro_implementation(PyTypeObject *type)
int i, n, ok;
PyObject *bases, *result;
+ if(type->tp_dict == NULL) {
+ if(PyType_Ready(type) < 0)
+ return NULL;
+ }
+
bases = type->tp_bases;
n = PyTuple_GET_SIZE(bases);
result = Py_BuildValue("[O]", (PyObject *)type);