Thread: pgsql: Fix pg_dump/pg_restore's ExecuteSqlCommand() to behave suitably

pgsql: Fix pg_dump/pg_restore's ExecuteSqlCommand() to behave suitably

From
tgl@postgresql.org (Tom Lane)
Date:
Log Message:
-----------
Fix pg_dump/pg_restore's ExecuteSqlCommand() to behave suitably if PQexec
returns NULL instead of a PGresult.  The former coding would fail, which
is OK, but it neglected to give you the PQerrorMessage that might tell
you why.  In the oldest branches, there was another problem: it'd sometimes
report PQerrorMessage from the wrong connection.

Tags:
----
REL8_1_STABLE

Modified Files:
--------------
    pgsql/src/bin/pg_dump:
        pg_backup_db.c (r1.66.2.2 -> r1.66.2.3)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/bin/pg_dump/pg_backup_db.c?r1=1.66.2.2&r2=1.66.2.3)