]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Remove assertion added by commit 7dcea51c2a4d
authorÁlvaro Herrera <alvherre@kurilemu.de>
Tue, 21 Jul 2026 15:18:02 +0000 (17:18 +0200)
committerÁlvaro Herrera <alvherre@kurilemu.de>
Tue, 21 Jul 2026 15:18:02 +0000 (17:18 +0200)
We've got no reports of problems.  Get rid of it.

Author: Álvaro Herrera <alvherre@kurilemu.de>
Backpatch-through: 19
Discussion: https://postgr.es/m/alewd1f2G0kKeM1i@alvherre.pgsql

src/backend/replication/logical/logical.c

index 3541fc793e4a45a3e3d7426b85b8bab8249d76e7..c30d40a86412761f07800ba5a23cbfdac2639d53 100644 (file)
@@ -2103,7 +2103,6 @@ LogicalSlotAdvanceAndCheckSnapState(XLogRecPtr moveto,
                                                                        bool *found_consistent_snapshot)
 {
        LogicalDecodingContext *ctx;
-       ResourceOwner old_resowner PG_USED_FOR_ASSERTS_ONLY = CurrentResourceOwner;
        XLogRecPtr      retlsn;
 
        Assert(XLogRecPtrIsValid(moveto));
@@ -2162,18 +2161,8 @@ LogicalSlotAdvanceAndCheckSnapState(XLogRecPtr moveto,
                         * might still have critical updates to do.
                         */
                        if (record)
-                       {
                                LogicalDecodingProcessRecord(ctx, ctx->reader);
 
-                               /*
-                                * We used to have bugs where logical decoding would fail to
-                                * preserve the resource owner.  That's important here, so
-                                * verify that that doesn't happen anymore.  XXX this could be
-                                * removed once it's been battle-tested.
-                                */
-                               Assert(CurrentResourceOwner == old_resowner);
-                       }
-
                        CHECK_FOR_INTERRUPTS();
                }