Use elog to report unexpected action in handle_streamed_transaction().
authorMasahiko Sawada <msawada@postgresql.org>
Mon, 24 Apr 2023 06:37:14 +0000 (15:37 +0900)
committerMasahiko Sawada <msawada@postgresql.org>
Mon, 24 Apr 2023 06:37:14 +0000 (15:37 +0900)
An oversight in commit 216a784829c.

Author: Masahiko Sawada
Reviewed-by: Kyotaro Horiguchi, Amit Kapila
Discussion: https://postgr.es/m/CAD21AoDDbM8_HJt-nMCvcjTK8K9hPzXWqJj7pyaUvR4mm_NrSg@mail.gmail.com

src/backend/replication/logical/worker.c

index 37bb88412790e38f139b0a0150ed904b46fa38d3..dbf88c9553191b48c91dc9510ad2d5e55d0b2c53 100644 (file)
@@ -658,7 +658,7 @@ handle_streamed_transaction(LogicalRepMsgType action, StringInfo s)
                        return false;
 
                default:
-                       Assert(false);
+                       elog(ERROR, "unexpected apply action: %d", (int) apply_action);
                        return false;           /* silence compiler warning */
        }
 }