Skip legacy LFC initialization when communicator is used

It clashes with the initialization of the LFC file
This commit is contained in:
Heikki Linnakangas
2025-07-05 12:58:01 +03:00
parent 6f3fb4433f
commit d6ec1f1a1c

View File

@@ -230,6 +230,8 @@ lfc_switch_off(void)
{
int fd;
Assert(!neon_enable_new_communicator);
if (LFC_ENABLED())
{
HASH_SEQ_STATUS status;
@@ -295,6 +297,8 @@ lfc_maybe_disabled(void)
static bool
lfc_ensure_opened(void)
{
Assert(!neon_enable_new_communicator);
if (lfc_generation != lfc_ctl->generation)
{
lfc_close_file();
@@ -320,6 +324,8 @@ lfc_shmem_startup(void)
bool found;
static HASHCTL info;
Assert(!neon_enable_new_communicator);
if (prev_shmem_startup_hook)
{
prev_shmem_startup_hook();
@@ -618,6 +624,9 @@ lfc_init(void)
if (lfc_max_size == 0)
return;
if (neon_enable_new_communicator)
return;
prev_shmem_startup_hook = shmem_startup_hook;
shmem_startup_hook = lfc_shmem_startup;
#if PG_VERSION_NUM>=150000