Skip to content
Browse files
Swap two lines of code so that if a connection attempt is cancelled, …
…SP does not try to open another connection to cancel the pending connection (#2909)
  • Loading branch information
dmoagx committed Nov 2, 2017
1 parent 3477d22 commit 273bd3720a857e4b886aa81b561854c250ea20e7
Showing 1 changed file with 2 additions and 2 deletions.
@@ -1007,11 +1007,11 @@ - (void)_disconnect

state = SPMySQLDisconnecting;

// If a query is active, cancel it
[self cancelCurrentQuery];

state = SPMySQLDisconnecting;

// Allow any pings or cancelled queries to complete, inside a time limit of ten seconds
uint64_t disconnectStartTime_t = mach_absolute_time();
while (![self _tryLockConnection]) {

0 comments on commit 273bd37

Please sign in to comment.