No need to call -stop from -dealloc

This commit is contained in:
Pierre-Olivier Latour
2014-04-30 13:36:06 -07:00
parent 56c096996f
commit 94ad8c745e
+1 -5
View File
@@ -199,11 +199,7 @@ static void _ConnectedTimerCallBack(CFRunLoopTimerRef timer, void* info) {
- (void)dealloc {
DCHECK(_connected == NO);
DCHECK(_activeConnections == 0);
_delegate = nil;
if (_options) {
[self stop];
}
DCHECK(_options == nil); // The server can never be dealloc'ed while running because of the retain-cycle with the dispatch source
CFRunLoopTimerInvalidate(_connectedTimer);
CFRelease(_connectedTimer);