]> granicus.if.org Git - postgresql/commitdiff
pg_basebackup: Error message improvements.
authorRobert Haas <rhaas@postgresql.org>
Wed, 28 Mar 2012 12:43:35 +0000 (08:43 -0400)
committerRobert Haas <rhaas@postgresql.org>
Wed, 28 Mar 2012 12:43:35 +0000 (08:43 -0400)
Fujii Masao

src/bin/pg_basebackup/pg_basebackup.c

index 4cb430b7e89b19e7017c0fe483e16d775fc9a32d..ac7a83481d01b88450f257d5887b3f0d8f3535d1 100644 (file)
@@ -914,7 +914,7 @@ BaseBackup(void)
        res = PQexec(conn, "IDENTIFY_SYSTEM");
        if (PQresultStatus(res) != PGRES_TUPLES_OK)
        {
-               fprintf(stderr, _("%s: could not identify system: %s\n"),
+               fprintf(stderr, _("%s: could not identify system: %s"),
                                progname, PQerrorMessage(conn));
                disconnect_and_exit(1);
        }
@@ -1049,8 +1049,8 @@ BaseBackup(void)
        res = PQgetResult(conn);
        if (PQresultStatus(res) != PGRES_TUPLES_OK)
        {
-               fprintf(stderr, _("%s: could not get WAL end position from server\n"),
-                               progname);
+               fprintf(stderr, _("%s: could not get WAL end position from server: %s"),
+                               progname, PQerrorMessage(conn));
                disconnect_and_exit(1);
        }
        if (PQntuples(res) != 1)