projects
/
users
/
kgrittn
/
postgres.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
110c88d
)
Make external_pid_file world readable
author
Peter Eisentraut
<peter_e@gmx.net>
Sat, 18 Jun 2011 21:34:32 +0000
(
00:34
+0300)
committer
Peter Eisentraut
<peter_e@gmx.net>
Sat, 18 Jun 2011 21:34:32 +0000
(
00:34
+0300)
src/backend/postmaster/postmaster.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/postmaster/postmaster.c
b/src/backend/postmaster/postmaster.c
index 1f0d4e63fb0ce0fdbb3ba0797aff65e28a420c4c..6572292a40f72f13a36c4eeaacf5be224bf4246f 100644
(file)
--- a/
src/backend/postmaster/postmaster.c
+++ b/
src/backend/postmaster/postmaster.c
@@
-1024,6
+1024,11
@@
PostmasterMain(int argc, char *argv[])
fprintf(fpidfile, "%d\n", MyProcPid);
fclose(fpidfile);
/* Should we remove the pid file on postmaster exit? */
+
+ /* Make PID file world readable */
+ if (chmod(external_pid_file, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH) != 0)
+ write_stderr("%s: could not change permissions of external PID file \"%s\": %s\n",
+ progname, external_pid_file, strerror(errno));
}
else
write_stderr("%s: could not write external PID file \"%s\": %s\n",