summaryrefslogtreecommitdiff
path: root/src/backend/storage/ipc/ipci.c
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2013-10-09 21:05:02 -0400
committerRobert Haas <rhaas@postgresql.org>2013-10-09 21:05:02 -0400
commit0ac5e5a7e152504c71ce2168acc9cef7fde7893c (patch)
tree9060ae6a71ae9b7ce5fda85846d3060cdc215432 /src/backend/storage/ipc/ipci.c
parentf566515192461acd8d9c232f48ddac3fc965cfd8 (diff)
Allow dynamic allocation of shared memory segments.
Patch by myself and Amit Kapila. Design help from Noah Misch. Review by Andres Freund.
Diffstat (limited to 'src/backend/storage/ipc/ipci.c')
-rw-r--r--src/backend/storage/ipc/ipci.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/backend/storage/ipc/ipci.c b/src/backend/storage/ipc/ipci.c
index a0b741b444a..040c7aa1044 100644
--- a/src/backend/storage/ipc/ipci.c
+++ b/src/backend/storage/ipc/ipci.c
@@ -30,6 +30,7 @@
#include "replication/walreceiver.h"
#include "replication/walsender.h"
#include "storage/bufmgr.h"
+#include "storage/dsm.h"
#include "storage/ipc.h"
#include "storage/pg_shmem.h"
#include "storage/pmsignal.h"
@@ -249,6 +250,10 @@ CreateSharedMemoryAndSemaphores(bool makePrivate, int port)
ShmemBackendArrayAllocation();
#endif
+ /* Initialize dynamic shared memory facilities. */
+ if (!IsUnderPostmaster)
+ dsm_postmaster_startup();
+
/*
* Now give loadable modules a chance to set up their shmem allocations
*/