aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPConnectionController.m
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2013-01-22 17:14:03 +0000
committerstuconnolly <stuart02@gmail.com>2013-01-22 17:14:03 +0000
commit9ab31cc5b60bf0e4519c989a3e9d213da50f888d (patch)
tree5e2967e092096dd830351a222cfe65d008d41fbd /Source/SPConnectionController.m
parente2cc9e1953a142f182714fb02d7eca028398e368 (diff)
downloadsequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.tar.gz
sequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.tar.bz2
sequelpro-9ab31cc5b60bf0e4519c989a3e9d213da50f888d.zip
Remove useless init and dealloc method comments and perform general tidy up.
Diffstat (limited to 'Source/SPConnectionController.m')
-rw-r--r--Source/SPConnectionController.m6
1 files changed, 4 insertions, 2 deletions
diff --git a/Source/SPConnectionController.m b/Source/SPConnectionController.m
index 18899cc5..52cb75bc 100644
--- a/Source/SPConnectionController.m
+++ b/Source/SPConnectionController.m
@@ -1815,21 +1815,23 @@ static NSComparisonResult _compareFavoritesUsingKey(id favorite1, id favorite2,
[(NSView *)favoritesOutlineView display];
}
-#pragma mark -
-
- (void)_documentWillClose:(NSNotification *)notification
{
cancellingConnection = YES;
dbDocument = nil;
+
if (mySQLConnection) {
[mySQLConnection setDelegate:nil];
[NSThread detachNewThreadWithName:@"SPConnectionController close background disconnect" target:mySQLConnection selector:@selector(disconnect) object:nil];
[mySQLConnection autorelease];
mySQLConnection = nil;
}
+
if (sshTunnel) [sshTunnel setConnectionStateChangeSelector:nil delegate:nil], [sshTunnel disconnect], [sshTunnel release];
}
+#pragma mark -
+
- (void)dealloc
{
[[NSNotificationCenter defaultCenter] removeObserver:self];