Skip to content

Commit b9c3047

Browse files
committed
check that module is in shared_preload_libraries
1 parent 4a87cd1 commit b9c3047

File tree

2 files changed

+2
-13
lines changed

2 files changed

+2
-13
lines changed

src/init.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,6 @@ init_shmem_config()
6464
pmstate->dsm_init_lock = LWLockAssign();
6565
pmstate->edit_partitions_lock = LWLockAssign();
6666
}
67-
#ifdef WIN32
68-
else
69-
{
70-
elog(ERROR, "Pathman module must be initialized in postmaster. "
71-
"Put the following line to configuration file: "
72-
"shared_preload_libraries='pg_pathman'");
73-
initialization_needed = false;
74-
}
75-
#endif
7667
}
7768

7869
create_relations_hashtable();

src/pg_pathman.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -126,15 +126,13 @@ static Path *get_cheapest_parameterized_child_path(PlannerInfo *root, RelOptInfo
126126
void
127127
_PG_init(void)
128128
{
129-
#ifndef WIN32
130-
if (IsUnderPostmaster)
129+
if (!process_shared_preload_libraries_in_progress)
131130
{
132131
elog(ERROR, "Pathman module must be initialized in postmaster. "
133132
"Put the following line to configuration file: "
134133
"shared_preload_libraries='pg_pathman'");
135-
initialization_needed = false;
134+
initialization_needed = false;
136135
}
137-
#endif
138136

139137
/* Request additional shared resources */
140138
RequestAddinShmemSpace(pathman_memsize());

0 commit comments

Comments
 (0)