diff options
| author | Simon Marlow <simonmar@microsoft.com> | 2007-06-13 11:15:52 +0000 |
|---|---|---|
| committer | Simon Marlow <simonmar@microsoft.com> | 2007-06-13 11:15:52 +0000 |
| commit | 61af839f961ea85dc80bed03313ee318fc02fa00 (patch) | |
| tree | 008ba892c14a661040cd620a19e8a3811fa82546 | |
| parent | 23e5985c3db852981d527d10d6a6271688049790 (diff) | |
| download | haskell-61af839f961ea85dc80bed03313ee318fc02fa00.tar.gz | |
another fix for -hb: we appear to be freeing the hash table and arena twice
| -rw-r--r-- | rts/ProfHeap.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/rts/ProfHeap.c b/rts/ProfHeap.c index ed5dc36009..f1a3b05ce4 100644 --- a/rts/ProfHeap.c +++ b/rts/ProfHeap.c @@ -343,8 +343,12 @@ initEra(Census *census) STATIC_INLINE void freeEra(Census *census) { - arenaFree(census->arena); - freeHashTable(census->hash, NULL); + if (RtsFlags.ProfFlags.bioSelector != NULL) + // when bioSelector==NULL, these are freed in heapCensus() + { + arenaFree(census->arena); + freeHashTable(census->hash, NULL); + } } /* -------------------------------------------------------------------------- |
