Convert erroneously forgotten printf debug to proper logging

This commit is contained in:
Ian Barwick
2016-05-24 16:44:22 +09:00
parent f63d42fe77
commit 9b2a907b09

View File

@@ -1694,8 +1694,6 @@ do_standby_clone(void)
/* XXX ensure this function does not exit on error as we'd need to stop the backup */ /* XXX ensure this function does not exit on error as we'd need to stop the backup */
read_backup_label(local_data_directory, &backup_label); read_backup_label(local_data_directory, &backup_label);
printf("Label: %s; file: %s\n", backup_label.label, backup_label.start_wal_file);
/* Handle tablespaces */ /* Handle tablespaces */
sqlquery_snprintf(sqlquery, sqlquery_snprintf(sqlquery,
@@ -2016,7 +2014,7 @@ stop_backup:
* rsync's --exclude option doesn't do it. * rsync's --exclude option doesn't do it.
*/ */
maxlen_snprintf(xlog_dir, "%s/pg_xlog/", local_data_directory); maxlen_snprintf(xlog_dir, "%s/pg_xlog/", local_data_directory);
if (!rmtree(xlog_dir, false)) if (!rmtree(xlog_dir, false))
{ {
@@ -2043,7 +2041,7 @@ stop_backup:
* functionality of replication slots * functionality of replication slots
*/ */
if (server_version_num >= 90400 && if (server_version_num >= 90400 &&
backup_label.min_failover_slot_lsn == InvalidXLogRecPtr) backup_label.min_failover_slot_lsn == InvalidXLogRecPtr)
{ {
maxlen_snprintf(script, "rm -rf %s/pg_replslot/*", maxlen_snprintf(script, "rm -rf %s/pg_replslot/*",
local_data_directory); local_data_directory);
@@ -2300,6 +2298,8 @@ read_backup_label(const char *local_data_directory, struct BackupLabel *out_back
} }
(void) fclose(label_file); (void) fclose(label_file);
log_debug(_("read_backup_label: label is %s; start wal file is %s\n"), out_backup_label->label, out_backup_label->start_wal_file);
} }
static void static void