Commit 6e374b7b authored by Jim Fulton's avatar Jim Fulton

Fixed (old) memory leak for DocumentTemplates wo validate.

parent 2bd55ac4
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
static char cDocumentTemplate_module_documentation[] = static char cDocumentTemplate_module_documentation[] =
"" ""
"\n$Id: cDocumentTemplate.c,v 1.11 1998/04/02 17:37:40 jim Exp $" "\n$Id: cDocumentTemplate.c,v 1.12 1998/04/02 21:17:41 jim Exp $"
; ;
#include "ExtensionClass.h" #include "ExtensionClass.h"
...@@ -141,10 +141,12 @@ InstanceDict_subscript( InstanceDictobject *self, PyObject *key) ...@@ -141,10 +141,12 @@ InstanceDict_subscript( InstanceDictobject *self, PyObject *key)
} }
} }
else else
UNLESS(r=PyObject_GetAttr(self->inst, key)) goto KeyError; UNLESS_ASSIGN(r, PyObject_GetAttr(self->inst, key)) goto KeyError;
} }
else else
{ {
PyErr_Clear();
/* OK, use getattr */ /* OK, use getattr */
UNLESS(r=PyObject_GetAttr(self->inst, key)) goto KeyError; UNLESS(r=PyObject_GetAttr(self->inst, key)) goto KeyError;
...@@ -828,7 +830,7 @@ void ...@@ -828,7 +830,7 @@ void
initcDocumentTemplate() initcDocumentTemplate()
{ {
PyObject *m, *d; PyObject *m, *d;
char *rev="$Revision: 1.11 $"; char *rev="$Revision: 1.12 $";
PURE_MIXIN_CLASS(cDocument, PURE_MIXIN_CLASS(cDocument,
"Base class for documents that adds fast validation method", "Base class for documents that adds fast validation method",
Document_methods); Document_methods);
...@@ -878,6 +880,9 @@ initcDocumentTemplate() ...@@ -878,6 +880,9 @@ initcDocumentTemplate()
Revision Log: Revision Log:
$Log: cDocumentTemplate.c,v $ $Log: cDocumentTemplate.c,v $
Revision 1.12 1998/04/02 21:17:41 jim
Fixed (old) memory leak for DocumentTemplates wo validate.
Revision 1.11 1998/04/02 17:37:40 jim Revision 1.11 1998/04/02 17:37:40 jim
Major redesign of block rendering. The code inside a block tag is Major redesign of block rendering. The code inside a block tag is
compiled as a template but only the templates blocks are saved, and compiled as a template but only the templates blocks are saved, and
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment