diff options
author | Magnus Hagander <magnus@hagander.net> | 2011-10-16 17:42:59 +0200 |
---|---|---|
committer | Magnus Hagander <magnus@hagander.net> | 2011-10-18 15:58:37 +0200 |
commit | d1e25b78f9988b9917de2818febcbf6c845c6ceb (patch) | |
tree | 12fa1394f9f75ca9a6a43f7655da86fcfb00984a /src | |
parent | 336c1d7a515b4d6de237679022d70082d7b69d9a (diff) | |
download | postgresql-d1e25b78f9988b9917de2818febcbf6c845c6ceb.tar.gz postgresql-d1e25b78f9988b9917de2818febcbf6c845c6ceb.zip |
Exclude postmaster.opts from base backups
Noted by Fujii Masao
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/replication/basebackup.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/backend/replication/basebackup.c b/src/backend/replication/basebackup.c index 4841095d176..20d4ce36d88 100644 --- a/src/backend/replication/basebackup.c +++ b/src/backend/replication/basebackup.c @@ -583,8 +583,9 @@ sendDir(char *path, int basepathlen, bool sizeonly) snprintf(pathbuf, MAXPGPATH, "%s/%s", path, de->d_name); - /* Skip postmaster.pid in the data directory */ - if (strcmp(pathbuf, "./postmaster.pid") == 0) + /* Skip postmaster.pid and postmaster.opts in the data directory */ + if (strcmp(pathbuf, "./postmaster.pid") == 0 || + strcmp(pathbuf, "./postmaster.opts") == 0) continue; if (lstat(pathbuf, &statbuf) != 0) |