X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=rts%2FStorage.c;h=0c9c60e58062538e3ba3535bb3564debffae8aa0;hp=d3b059768b09edcc0ef8bc65e2d5c6a83547dd43;hb=c76c69c5b62f1ca4fa52d75b0dfbd37b7eddbb09;hpb=9f2ceb4da7dfbc1cfd09ce54610ebe64288b9007 diff --git a/rts/Storage.c b/rts/Storage.c index d3b0597..0c9c60e 100644 --- a/rts/Storage.c +++ b/rts/Storage.c @@ -127,7 +127,7 @@ initStorage( void ) RtsFlags.GcFlags.minAllocAreaSize > RtsFlags.GcFlags.maxHeapSize) { errorBelch("maximum heap size (-M) is smaller than minimum alloc area size (-A)"); - exit(1); + RtsFlags.GcFlags.minAllocAreaSize = RtsFlags.GcFlags.maxHeapSize; } initBlockAllocator(); @@ -279,6 +279,10 @@ freeStorage (void) stgFree(generations[g].steps); stgFree(generations); freeAllMBlocks(); +#if defined(THREADED_RTS) + closeMutex(&sm_mutex); + closeMutex(&atomic_modify_mutvar_mutex); +#endif } /* -----------------------------------------------------------------------------