From 8a28dadde4f0ada4ca2ee6edf30f51264c87361f Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Tue, 26 Jul 2016 09:19:52 +0900 Subject: [PATCH] Rename RECOVERY_FILE to RECOVERY_COMMAND_FILE This is for consistency with the PostgreSQL source code (see: src/backend/access/transam/xlog.c ), but as it's not exported we need to define it ourselves anyway. --- repmgr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/repmgr.c b/repmgr.c index 998b709e..70075d95 100644 --- a/repmgr.c +++ b/repmgr.c @@ -59,7 +59,9 @@ #include "strutil.h" #include "version.h" -#define RECOVERY_FILE "recovery.conf" +#ifndef RECOVERY_COMMAND_FILE +#define RECOVERY_COMMAND_FILE "recovery.conf" +#endif #ifndef TABLESPACE_MAP #define TABLESPACE_MAP "tablespace_map" @@ -4389,7 +4391,7 @@ create_recovery_file(const char *data_dir, PGconn *primary_conn) char recovery_file_path[MAXLEN]; char line[MAXLEN]; - maxlen_snprintf(recovery_file_path, "%s/%s", data_dir, RECOVERY_FILE); + maxlen_snprintf(recovery_file_path, "%s/%s", data_dir, RECOVERY_COMMAND_FILE); recovery_file = fopen(recovery_file_path, "w"); if (recovery_file == NULL)