diff options
| author | Tom Lane | 2014-04-04 22:42:13 +0000 |
|---|---|---|
| committer | Tom Lane | 2014-04-04 22:42:13 +0000 |
| commit | 9aca51250681d2e8d18ed1d73e7cd1283d1cf303 (patch) | |
| tree | b1b9e945db659fd59bbdf8aacf3f21aad18f5b15 /src/include | |
| parent | 8120c7452a51a773ad7a249b55557439f39d41ef (diff) | |
Make sure -D is an absolute path when starting server on Windows.
This is needed because Windows services may get started with a different
current directory than where pg_ctl is executed. We want relative -D
paths to be interpreted relative to pg_ctl's CWD, similarly to what
happens on other platforms.
In support of this, move the backend's make_absolute_path() function
into src/port/path.c (where it probably should have been long since)
and get rid of the rather inferior version in pg_regress.
Kumar Rajeev Rastogi, reviewed by MauMau
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/miscadmin.h | 1 | ||||
| -rw-r--r-- | src/include/port.h | 1 |
2 files changed, 1 insertions, 1 deletions
diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h index 947906a280..0d61b82eb5 100644 --- a/src/include/miscadmin.h +++ b/src/include/miscadmin.h @@ -296,7 +296,6 @@ extern void SetCurrentRoleId(Oid roleid, bool is_superuser); extern void SetDataDir(const char *dir); extern void ChangeToDataDir(void); -extern char *make_absolute_path(const char *path); /* in utils/misc/superuser.c */ extern bool superuser(void); /* current user is superuser */ diff --git a/src/include/port.h b/src/include/port.h index aeb7754cb0..06986858b6 100644 --- a/src/include/port.h +++ b/src/include/port.h @@ -45,6 +45,7 @@ extern void make_native_path(char *path); extern bool path_contains_parent_reference(const char *path); extern bool path_is_relative_and_below_cwd(const char *path); extern bool path_is_prefix_of_path(const char *path1, const char *path2); +extern char *make_absolute_path(const char *path); extern const char *get_progname(const char *argv0); extern void get_share_path(const char *my_exec_path, char *ret_path); extern void get_etc_path(const char *my_exec_path, char *ret_path); |
