mirror of
https://github.com/gnustep/libs-sqlclient.git
synced 2025-02-11 08:30:42 +00:00
Prevent runaway looping if database connection is lost: re-establish connection to database before retrying quuery/execute.
This commit is contained in:
parent
267987d01c
commit
a8f405c563
1 changed files with 4 additions and 2 deletions
|
@ -2909,9 +2909,10 @@ static int poolConnections = 0;
|
|||
{
|
||||
NSLog(@"Will retry after: %@", localException);
|
||||
}
|
||||
[self connect];
|
||||
}
|
||||
}
|
||||
if (done == YES)
|
||||
if (done)
|
||||
{
|
||||
[lock unlock];
|
||||
[localException raise];
|
||||
|
@ -2987,9 +2988,10 @@ static int poolConnections = 0;
|
|||
{
|
||||
NSLog(@"Will retry after: %@", localException);
|
||||
}
|
||||
[self connect];
|
||||
}
|
||||
}
|
||||
if (YES == done)
|
||||
if (done)
|
||||
{
|
||||
[lock unlock];
|
||||
[localException raise];
|
||||
|
|
Loading…
Reference in a new issue