Skip to content

Commit 9477f12

Browse files
committed
Fix caching of unsuccessful initialization of parser or configuration.
Per report from Listmail <lists@peufeu.com>
1 parent 57690c6 commit 9477f12

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

contrib/tsearch2/ts_cfg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,8 +224,8 @@ findcfg(Oid id)
224224
CList.reallen = reallen;
225225
CList.list = tmp;
226226
}
227+
init_cfg(id, &(CList.list[CList.len]) );
227228
CList.last_cfg = &(CList.list[CList.len]);
228-
init_cfg(id, CList.last_cfg);
229229
CList.len++;
230230
qsort(CList.list, CList.len, sizeof(TSCfgInfo), comparecfg);
231231
return findcfg(id); /* qsort changed order!! */ ;

contrib/tsearch2/wparser.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ findprs(Oid id)
127127
PList.reallen = reallen;
128128
PList.list = tmp;
129129
}
130+
init_prs(id, &(PList.list[PList.len]) );
130131
PList.last_prs = &(PList.list[PList.len]);
131-
init_prs(id, PList.last_prs);
132132
PList.len++;
133133
qsort(PList.list, PList.len, sizeof(WParserInfo), compareprs);
134134
return findprs(id); /* qsort changed order!! */ ;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy