From a9b6a61623dae2ebb05efa200b048819b5fcfd2c Mon Sep 17 00:00:00 2001 From: Thomas Munro Date: Thu, 13 Sep 2018 15:18:37 +1200 Subject: [PATCH 1/3] hack to make unaccent crash in parallel workers --- contrib/unaccent/unaccent.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/contrib/unaccent/unaccent.c b/contrib/unaccent/unaccent.c index dbf2bb9602..130e61c51b 100644 --- a/contrib/unaccent/unaccent.c +++ b/contrib/unaccent/unaccent.c @@ -26,6 +26,14 @@ PG_MODULE_MAGIC; +void _PG_init(void); + +void +_PG_init(void) +{ + SearchSysCache1(PROCOID, ObjectIdGetDatum(999999)); +} + /* * An unaccent dictionary uses a trie to find a string to replace. Each node * of the trie is an array of 256 TrieChar structs; the N-th element of the -- 2.17.0