diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c index 37c0eda510a..7b9b483ed97 100644 --- a/src/backend/access/transam/xlog.c +++ b/src/backend/access/transam/xlog.c @@ -2809,6 +2809,11 @@ XLogFileRead(uint32 log, uint32 seg, int emode, TimeLineID tli, errmsg("could not rename file \"%s\" to \"%s\": %m", path, xlogfpath))); + /* + * Set path to point at the new file in pg_xlog. + */ + strncpy(path, xlogfpath, MAXPGPATH); + /* * If the existing segment was replaced, since walsenders might have * it open, request them to reload a currently-open segment.