Merge pull request #143 from MasahikoSawada/fix_lock_exclusive
Reset the transcation state before exiting from lock_exclusive.
This commit is contained in:
commit
b2d470a122
@ -1780,6 +1780,12 @@ lock_exclusive(PGconn *conn, const char *relid, const char *lock_query, bool sta
|
|||||||
{
|
{
|
||||||
elog(WARNING, "timed out, do not cancel conflicting backends");
|
elog(WARNING, "timed out, do not cancel conflicting backends");
|
||||||
ret = false;
|
ret = false;
|
||||||
|
|
||||||
|
/* Before exit the loop reset the transaction */
|
||||||
|
if (start_xact)
|
||||||
|
pgut_rollback(conn);
|
||||||
|
else
|
||||||
|
pgut_command(conn, "ROLLBACK TO SAVEPOINT repack_sp1", 0, NULL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user