Permalink
Browse files

Fix a rare timing-sensitive crash when closing a window during a conn…

…ection attempt (part of #2924)
  • Loading branch information...
dmoagx committed Nov 17, 2017
1 parent 6734907 commit b9a2d6c138a477092ea63b209ed00f8bf47e331b
Showing with 4 additions and 1 deletion.
  1. +4 −1 Source/SPDatabaseDocument.m
@@ -6534,8 +6534,11 @@ - (void)dealloc
if (processListController) [processListController close];
// #2924: The connection controller doesn't retain its delegate (us), but it may outlive us (e.g. when running a bg thread)
[connectionController setDelegate:nil];
SPClear(connectionController);
if (selectedTableName) SPClear(selectedTableName);
if (connectionController) SPClear(connectionController);
if (processListController) SPClear(processListController);
if (serverVariablesController) SPClear(serverVariablesController);
if (mySQLConnection) SPClear(mySQLConnection);

0 comments on commit b9a2d6c

Please sign in to comment.