diff --git a/Modules/cPickle.c b/Modules/cPickle.c index 0b36e7ef03..df564d44b3 100644 --- a/Modules/cPickle.c +++ b/Modules/cPickle.c @@ -3394,11 +3394,11 @@ load_string(Unpicklerobject *self) /********************************************/ str = PyString_DecodeEscape(p, len, NULL, 0, NULL); + free(s); if (str) { PDATA_PUSH(self->stack, str, -1); res = 0; } - free(s); return res; insecure: