From 21ef088265e20cdc2c7cff50eab432f8c620da01 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Fri, 11 Dec 1998 03:20:00 +0000 Subject: [PATCH] Need to initialize self->safe_constructors early on to prevent crash in early dealloc. Patch by Andrew Dalke. --- Modules/cPickle.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Modules/cPickle.c b/Modules/cPickle.c index 90e56109435..a73a7874f5e 100644 --- a/Modules/cPickle.c +++ b/Modules/cPickle.c @@ -3865,6 +3865,7 @@ newUnpicklerobject(PyObject *f) { self->buf_size = 0; self->read = NULL; self->readline = NULL; + self->safe_constructors = NULL; UNLESS (self->memo = PyDict_New()) { Py_XDECREF((PyObject *)self);