aboutsummaryrefslogtreecommitdiff
path: root/src/bin/pg_rewind
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/pg_rewind')
-rw-r--r--src/bin/pg_rewind/filemap.c10
-rw-r--r--src/bin/pg_rewind/libpq_fetch.c4
-rw-r--r--src/bin/pg_rewind/parsexlog.c2
-rw-r--r--src/bin/pg_rewind/pg_rewind.c22
4 files changed, 19 insertions, 19 deletions
diff --git a/src/bin/pg_rewind/filemap.c b/src/bin/pg_rewind/filemap.c
index 813eadcb017..3c7ef900139 100644
--- a/src/bin/pg_rewind/filemap.c
+++ b/src/bin/pg_rewind/filemap.c
@@ -508,10 +508,10 @@ check_file_excluded(const char *path, bool is_source)
{
if (is_source)
pg_log_debug("entry \"%s\" excluded from source file list",
- path);
+ path);
else
pg_log_debug("entry \"%s\" excluded from target file list",
- path);
+ path);
return true;
}
}
@@ -528,10 +528,10 @@ check_file_excluded(const char *path, bool is_source)
{
if (is_source)
pg_log_debug("entry \"%s\" excluded from source file list",
- path);
+ path);
else
pg_log_debug("entry \"%s\" excluded from target file list",
- path);
+ path);
return true;
}
}
@@ -659,7 +659,7 @@ print_filemap(void)
entry->pagemap.bitmapsize > 0)
{
pg_log_debug("%s (%s)", entry->path,
- action_to_str(entry->action));
+ action_to_str(entry->action));
if (entry->pagemap.bitmapsize > 0)
datapagemap_print(&entry->pagemap);
diff --git a/src/bin/pg_rewind/libpq_fetch.c b/src/bin/pg_rewind/libpq_fetch.c
index b6fa7e5b09c..d6cbe23926a 100644
--- a/src/bin/pg_rewind/libpq_fetch.c
+++ b/src/bin/pg_rewind/libpq_fetch.c
@@ -320,7 +320,7 @@ receiveFileChunks(const char *sql)
if (PQgetisnull(res, 0, 2))
{
pg_log_debug("received null value for chunk for file \"%s\", file has been deleted",
- filename);
+ filename);
remove_target_file(filename, true);
pg_free(filename);
PQclear(res);
@@ -333,7 +333,7 @@ receiveFileChunks(const char *sql)
*/
snprintf(chunkoff_str, sizeof(chunkoff_str), INT64_FORMAT, chunkoff);
pg_log_debug("received chunk for file \"%s\", offset %s, size %d",
- filename, chunkoff_str, chunksize);
+ filename, chunkoff_str, chunksize);
open_target_file(filename, false);
diff --git a/src/bin/pg_rewind/parsexlog.c b/src/bin/pg_rewind/parsexlog.c
index 65e523f5d4e..b31071bc09d 100644
--- a/src/bin/pg_rewind/parsexlog.c
+++ b/src/bin/pg_rewind/parsexlog.c
@@ -315,7 +315,7 @@ SimpleXLogPageRead(XLogReaderState *xlogreader, XLogRecPtr targetPagePtr,
pg_log_error("could not read file \"%s\": %m", xlogfpath);
else
pg_log_error("could not read file \"%s\": read %d of %zu",
- xlogfpath, r, (Size) XLOG_BLCKSZ);
+ xlogfpath, r, (Size) XLOG_BLCKSZ);
return -1;
}
diff --git a/src/bin/pg_rewind/pg_rewind.c b/src/bin/pg_rewind/pg_rewind.c
index d47b5f9648f..6cd39176285 100644
--- a/src/bin/pg_rewind/pg_rewind.c
+++ b/src/bin/pg_rewind/pg_rewind.c
@@ -52,7 +52,7 @@ char *datadir_target = NULL;
char *datadir_source = NULL;
char *connstr_source = NULL;
-static bool debug = false;
+static bool debug = false;
bool showprogress = false;
bool dry_run = false;
bool do_sync = true;
@@ -260,8 +260,8 @@ main(int argc, char **argv)
{
findCommonAncestorTimeline(&divergerec, &lastcommontliIndex);
pg_log_info("servers diverged at WAL location %X/%X on timeline %u",
- (uint32) (divergerec >> 32), (uint32) divergerec,
- targetHistory[lastcommontliIndex].tli);
+ (uint32) (divergerec >> 32), (uint32) divergerec,
+ targetHistory[lastcommontliIndex].tli);
/*
* Check for the possibility that the target is in fact a direct
@@ -304,8 +304,8 @@ main(int argc, char **argv)
lastcommontliIndex,
&chkptrec, &chkpttli, &chkptredo);
pg_log_info("rewinding from last common checkpoint at %X/%X on timeline %u",
- (uint32) (chkptrec >> 32), (uint32) chkptrec,
- chkpttli);
+ (uint32) (chkptrec >> 32), (uint32) chkptrec,
+ chkpttli);
/*
* Build the filemap, by comparing the source and target data directories.
@@ -344,8 +344,8 @@ main(int argc, char **argv)
if (showprogress)
{
pg_log_info("need to copy %lu MB (total source directory size is %lu MB)",
- (unsigned long) (filemap->fetch_size / (1024 * 1024)),
- (unsigned long) (filemap->total_size / (1024 * 1024)));
+ (unsigned long) (filemap->fetch_size / (1024 * 1024)),
+ (unsigned long) (filemap->total_size / (1024 * 1024)));
fetch_size = filemap->fetch_size;
fetch_done = 0;
@@ -495,8 +495,8 @@ progress_report(bool force)
fetch_size / 1024);
fprintf(stderr, _("%*s/%s kB (%d%%) copied"),
- (int) strlen(fetch_size_str), fetch_done_str, fetch_size_str,
- percent);
+ (int) strlen(fetch_size_str), fetch_done_str, fetch_size_str,
+ percent);
if (isatty(fileno(stderr)))
fprintf(stderr, "\r");
else
@@ -581,8 +581,8 @@ getTimelineHistory(ControlFileData *controlFile, int *nentries)
entry = &history[i];
pg_log_debug("%d: %X/%X - %X/%X", entry->tli,
- (uint32) (entry->begin >> 32), (uint32) (entry->begin),
- (uint32) (entry->end >> 32), (uint32) (entry->end));
+ (uint32) (entry->begin >> 32), (uint32) (entry->begin),
+ (uint32) (entry->end >> 32), (uint32) (entry->end));
}
}