File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 8
8
*
9
9
*
10
10
* IDENTIFICATION
11
- * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.24 2000/01/31 04:35:53 tgl Exp $
11
+ * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.25 2000/03/08 23:42:58 tgl Exp $
12
12
*
13
13
* NOTE:
14
14
* This is a new (Feb. 05, 1999) implementation of the allocation set
@@ -173,6 +173,10 @@ AllocSetReset(AllocSet set)
173
173
while (block != NULL )
174
174
{
175
175
next = block -> next ;
176
+ #ifdef CLOBBER_FREED_MEMORY
177
+ /* Wipe freed memory for debugging purposes */
178
+ memset (block , 0x7F , ((char * ) block -> endptr ) - ((char * ) block ));
179
+ #endif
176
180
free (block );
177
181
block = next ;
178
182
}
@@ -419,6 +423,10 @@ AllocSetFree(AllocSet set, AllocPointer pointer)
419
423
set -> blocks = block -> next ;
420
424
else
421
425
prevblock -> next = block -> next ;
426
+ #ifdef CLOBBER_FREED_MEMORY
427
+ /* Wipe freed memory for debugging purposes */
428
+ memset (block , 0x7F , ((char * ) block -> endptr ) - ((char * ) block ));
429
+ #endif
422
430
free (block );
423
431
}
424
432
else
You can’t perform that action at this time.
0 commit comments