Don't fail on libpq-generated error reports in pg_amcheck.
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 6 Jun 2022 15:26:57 +0000 (11:26 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 6 Jun 2022 15:26:57 +0000 (11:26 -0400)
commit51da231597a9e414174cf621b219559e18269dc3
tree823836f62bae8b7852fafe274559825b76372370
parent6d157e7cb8d3f4aa28a9fef95c498ce8ac3c31a9
Don't fail on libpq-generated error reports in pg_amcheck.

An error PGresult generated by libpq itself, such as a report of
connection loss, won't have broken-down error fields.
should_processing_continue() blithely assumed that
PG_DIAG_SEVERITY_NONLOCALIZED would always be present, and would
dump core if it wasn't.

Per grepping to see if 6d157e7cb's mistake was repeated elsewhere.
src/bin/pg_amcheck/pg_amcheck.c