aboutsummaryrefslogtreecommitdiff
path: root/src/bin/pg_rewind/libpq_fetch.c
diff options
context:
space:
mode:
authorAlvaro Herrera <alvherre@alvh.no-ip.org>2017-09-04 11:08:52 +0200
committerAlvaro Herrera <alvherre@alvh.no-ip.org>2017-09-04 11:09:51 +0200
commitbd75335a83bf0564d6d256d1b78499a5ea489d74 (patch)
tree0456e4c542a53f60345cc51f45c2af03d995a71f /src/bin/pg_rewind/libpq_fetch.c
parenta4b0a4d437dc71839999c0d5bed23445abf82d88 (diff)
downloadpostgresql-bd75335a83bf0564d6d256d1b78499a5ea489d74.tar.gz
postgresql-bd75335a83bf0564d6d256d1b78499a5ea489d74.zip
Fix translatable string
Discussion: https://postgr.es/m/20170828130545.sdajqlpr37hmmd6a@alvherre.pgsql
Diffstat (limited to 'src/bin/pg_rewind/libpq_fetch.c')
-rw-r--r--src/bin/pg_rewind/libpq_fetch.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/bin/pg_rewind/libpq_fetch.c b/src/bin/pg_rewind/libpq_fetch.c
index e90907bd380..189853b3f14 100644
--- a/src/bin/pg_rewind/libpq_fetch.c
+++ b/src/bin/pg_rewind/libpq_fetch.c
@@ -271,6 +271,7 @@ receiveFileChunks(const char *sql)
char *filename;
int filenamelen;
int64 chunkoff;
+ char chunkoff_str[32];
int chunksize;
char *chunk;
@@ -343,8 +344,13 @@ receiveFileChunks(const char *sql)
continue;
}
- pg_log(PG_DEBUG, "received chunk for file \"%s\", offset " INT64_FORMAT ", size %d\n",
- filename, chunkoff, chunksize);
+ /*
+ * Separate step to keep platform-dependent format code out of
+ * translatable strings.
+ */
+ snprintf(chunkoff_str, sizeof(chunkoff_str), INT64_FORMAT, chunkoff);
+ pg_log(PG_DEBUG, "received chunk for file \"%s\", offset %s, size %d\n",
+ filename, chunkoff_str, chunksize);
open_target_file(filename, false);