From 23de25f49c94fbc3fb4d9ab22a041044ed668c30 Mon Sep 17 00:00:00 2001 From: stuconnolly Date: Tue, 21 Jul 2009 17:51:40 +0000 Subject: To prevent a deadlock situation in fetchMaxAllowedPacket, query lock must be unlocked as serverMajorVersion performs a query and thus attempts to obtain the lock. --- Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Frameworks/MCPKit') diff --git a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m index fb0dcc10..94b610bc 100644 --- a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m +++ b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m @@ -1802,8 +1802,8 @@ static void forcePingTimeout(int signalNumber) NSArray *a = [r fetchRowAsArray]; [r autorelease]; if([a count]) { - maxAllowedPacketSize = [[a objectAtIndex:([self serverMajorVersion] == 3)?1:0] intValue]; [queryLock unlock]; + maxAllowedPacketSize = [[a objectAtIndex:([self serverMajorVersion] == 3)?1:0] intValue]; return true; } } -- cgit v1.2.3