projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2e02136
)
Ignore WL_POSTMASTER_DEATH latch event in single user mode
author
Peter Eisentraut
<
[email protected]
>
Sat, 3 Jun 2017 03:02:13 +0000
(23:02 -0400)
committer
Peter Eisentraut
<
[email protected]
>
Tue, 6 Jun 2017 01:03:35 +0000
(21:03 -0400)
Otherwise code that uses this will abort with an assertion failure,
because postmaster_alive_fds are not initialized.
Reported-by: tushar <
[email protected]
>
src/backend/storage/ipc/latch.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/storage/ipc/latch.c
b/src/backend/storage/ipc/latch.c
index 53e6bf2477ddbba5c3e711dc5810c45119af029e..55959de91f3bf36527bb4898ad65a4422efc9421 100644
(file)
--- a/
src/backend/storage/ipc/latch.c
+++ b/
src/backend/storage/ipc/latch.c
@@
-370,7
+370,7
@@
WaitLatchOrSocket(volatile Latch *latch, int wakeEvents, pgsocket sock,
AddWaitEventToSet(set, WL_LATCH_SET, PGINVALID_SOCKET,
(Latch *) latch, NULL);
- if (wakeEvents & WL_POSTMASTER_DEATH)
+ if (wakeEvents & WL_POSTMASTER_DEATH
&& IsUnderPostmaster
)
AddWaitEventToSet(set, WL_POSTMASTER_DEATH, PGINVALID_SOCKET,
NULL, NULL);