Skip to content

Commit 250f259

Browse files
pg_basebackup streaming: adjust version check msg
Allow for translatable string, rather than use "or"
1 parent 7c7b1f4 commit 250f259

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

src/bin/pg_basebackup/receivelog.c

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -367,14 +367,24 @@ CheckServerVersionForStreaming(PGconn *conn)
367367
minServerMajor = 903;
368368
maxServerMajor = PG_VERSION_NUM / 100;
369369
serverMajor = PQserverVersion(conn) / 100;
370-
if (serverMajor < minServerMajor || serverMajor > maxServerMajor)
370+
if (serverMajor < minServerMajor)
371371
{
372372
const char *serverver = PQparameterStatus(conn, "server_version");
373373

374-
fprintf(stderr, _("%s: incompatible server version %s; streaming is only supported with server version %s\n"),
374+
fprintf(stderr, _("%s: incompatible server version %s; client does not support streaming from server versions older than %s\n"),
375375
progname,
376376
serverver ? serverver : "'unknown'",
377-
"9.3 or 9.4");
377+
"9.3");
378+
return false;
379+
}
380+
else if (serverMajor > maxServerMajor)
381+
{
382+
const char *serverver = PQparameterStatus(conn, "server_version");
383+
384+
fprintf(stderr, _("%s: incompatible server version %s; client does not support streaming from server versions newer than %s\n"),
385+
progname,
386+
serverver ? serverver : "'unknown'",
387+
PG_VERSION);
378388
return false;
379389
}
380390
return true;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy