Message string improvements

This commit is contained in:
Peter Eisentraut 2015-05-18 23:01:48 -04:00
parent 0779f2ba2d
commit 55c0da38be
3 changed files with 8 additions and 6 deletions

View File

@ -479,17 +479,19 @@ main(int argc, char **argv)
exit(1);
}
if (replication_slot == NULL && (do_drop_slot || do_create_slot))
if (do_drop_slot && do_create_slot)
{
fprintf(stderr, _("%s: --create-slot and --drop-slot need a slot to be specified using --slot\n"), progname);
fprintf(stderr, _("%s: cannot use --create-slot together with --drop-slot\n"), progname);
fprintf(stderr, _("Try \"%s --help\" for more information.\n"),
progname);
exit(1);
}
if (do_drop_slot && do_create_slot)
if (replication_slot == NULL && (do_drop_slot || do_create_slot))
{
fprintf(stderr, _("%s: cannot use --create-slot together with --drop-slot\n"), progname);
/* translator: second %s is an option name */
fprintf(stderr, _("%s: %s needs a slot to be specified using --slot\n"), progname,
do_drop_slot ? "--drop-slot" : "--create-slot");
fprintf(stderr, _("Try \"%s --help\" for more information.\n"),
progname);
exit(1);

View File

@ -852,7 +852,7 @@ main(int argc, char **argv)
if (db_name == NULL)
{
fprintf(stderr,
_("%s: failed to establish database specific replication connection\n"),
_("%s: could not establish database-specific replication connection\n"),
progname);
disconnect_and_exit(1);
}

View File

@ -694,7 +694,7 @@ verify_peer_name_matches_certificate(PGconn *conn)
else
{
printfPQExpBuffer(&conn->errorMessage,
libpq_gettext("could not get server's hostname from server certificate\n"));
libpq_gettext("could not get server's host name from server certificate\n"));
}
}