pgsql: Use ereport(ERROR) instead of Assert() to emit syncrep_parser er - Mailing list pgsql-committers

From Fujii Masao
Subject pgsql: Use ereport(ERROR) instead of Assert() to emit syncrep_parser er
Date
Msg-id E1apViy-00035s-MX@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Use ereport(ERROR) instead of Assert() to emit syncrep_parser error.

The existing code would either Assert or generate an invalid
SyncRepConfig variable, neither of which is desirable. A regular
error should be thrown instead.

This commit silences compiler warning in non assertion-enabled builds.

Per report from Jeff Janes.
Suggested fix by Tom Lane.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/0038c1e2181b520a9307aae6587e110468072392

Modified Files
--------------
src/backend/replication/syncrep.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Fix poorly thought-through code from commit 5c3c3cd0a3046339.
Next
From: Fujii Masao
Date:
Subject: pgsql: Fix documented return type of pg_logical_emit_message() in func.