summaryrefslogtreecommitdiff
path: root/src/stream_template.c
diff options
context:
space:
mode:
authorakuchling <akuchling@rivest.dlitz.net>2002-05-23 14:02:59 -0700
committerakuchling <akuchling@rivest.dlitz.net>2002-05-23 14:02:59 -0700
commit756116d7c639c53ecbe4da2c5c276875e4c646a0 (patch)
treedd5528986ffb6065a9040daa54b74ea62fdd2bf1 /src/stream_template.c
parentf5580c2be024cd6e7a223d2d3244227e845c965c (diff)
downloadpycrypto-756116d7c639c53ecbe4da2c5c276875e4c646a0.tar.gz
[project @ akuchling-20020523210259-f80d7b91276c43b2]
[project @ 2002-05-23 14:02:58 by akuchling] Make the deallocators consistent
Diffstat (limited to 'src/stream_template.c')
-rw-r--r--src/stream_template.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/stream_template.c b/src/stream_template.c
index c849aa9..325dc44 100644
--- a/src/stream_template.c
+++ b/src/stream_template.c
@@ -55,14 +55,15 @@ newALGobject(void)
}
static void
-ALGdealloc(PyObject *self)
+ALGdealloc(PyObject *ptr)
{
int i;
+ char *obj=(char *)ptr;
- /* Overwrite the contents of the object, just in case... */
+ /* Overwrite the contents of the object, just in case... */
for (i = 0; i < sizeof(ALGobject); i++)
- *((char *) self + i) = '\0';
- PyObject_DEL(self);
+ *(obj + i) = '\0';
+ PyObject_DEL(ptr);
}
static char ALGnew__doc__[] =