@@ -293,29 +293,24 @@ return self; } - (void)dealloc { - void *pool = objc_autoreleasePoolPush(); [_queueCondition lock]; @try { [_countCondition lock]; @try { - OFEnumerator *enumerator = [_threads objectEnumerator]; - OFThreadPoolThread *thread; - - while ((thread = [enumerator nextObject]) != nil) + for (OFThreadPoolThread *thread in _threads) thread->_terminate = true; } @finally { [_countCondition unlock]; } [_queueCondition broadcast]; } @finally { [_queueCondition unlock]; } - objc_autoreleasePoolPop(pool); [_threads release]; [_queue release]; [_queueCondition release]; [_countCondition release];