diff options
author | Pavan Deolasee | 2015-06-23 07:54:00 +0000 |
---|---|---|
committer | Pavan Deolasee | 2015-06-23 07:54:00 +0000 |
commit | 289cba11506536aa156c14e322ab09b8a8b7a21c (patch) | |
tree | 09d4e32dee8604ebcb55468e270333a8cc5ddbe1 | |
parent | 76d872716abb5acf291c328b1894a06f1ccfabd3 (diff) |
Always pass InvalidBackendId to relpath()
While its not entirely clear if this is a safe change, it restores pre-merge
behaviour and also fixes errors during buffer sync belonging to temporary
tables. Since buffer header tag does not track BackendId, without this change,
we arrive at different relation file path, while creation and then later at
sync. (This is a non-issue for vanilla Postgres because temp tables are never
written or fsynced in vanilla Postgres)
-rw-r--r-- | src/include/common/relpath.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/include/common/relpath.h b/src/include/common/relpath.h index 6bb2c62611..15bb5d8a68 100644 --- a/src/include/common/relpath.h +++ b/src/include/common/relpath.h @@ -85,7 +85,11 @@ extern char *GetRelationPath_client(Oid dbNode, Oid spcNode, Oid relNode, #endif /* First argument is a RelFileNodeBackend */ +#ifdef XCP +#define relpath(rnode, forknum) \ + relpathbackend((rnode).node, InvalidBackendId, forknum) +#else #define relpath(rnode, forknum) \ relpathbackend((rnode).node, (rnode).backend, forknum) - +#endif #endif /* RELPATH_H */ |