From f64992e95d3b87799d4a423d2d0c0047b177c56b Mon Sep 17 00:00:00 2001 From: Sjoerd Mullender Date: Tue, 3 Aug 1993 15:11:36 +0000 Subject: * clmodule.c (doParams): free PVbuffer in error condition. * frameobject.c (newframeobject): initialize ob_type if taking entry from the free list, since it is zeroed out when DEBUG is defined. --- Modules/clmodule.c | 4 +++- Objects/frameobject.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Modules/clmodule.c b/Modules/clmodule.c index a9a378e..63e81db 100644 --- a/Modules/clmodule.c +++ b/Modules/clmodule.c @@ -365,8 +365,10 @@ doParams(clobject *self, object *args, int (*func)(CL_Handle, int *, int), error_handler_called = 0; (*func)(self->ob_compressorHdl, PVbuffer, length); - if (error_handler_called) + if (error_handler_called) { + DEL(PVbuffer); return NULL; + } if (modified) { for (i = 0; i < length; i++) { diff --git a/Objects/frameobject.c b/Objects/frameobject.c index 62a18e2..0b5e75c 100644 --- a/Objects/frameobject.c +++ b/Objects/frameobject.c @@ -137,6 +137,7 @@ newframeobject(back, code, globals, locals, owner, nvalues, nblocks) else { f = free_list; free_list = free_list->f_back; + f->ob_type = &Frametype; NEWREF(f); } if (f != NULL) { -- cgit v0.12