summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane2007-07-15 22:57:48 +0000
committerTom Lane2007-07-15 22:57:48 +0000
commit0be53809a84f41fd27ec45d66a5431f90c13e609 (patch)
tree78a5a24ac2e55ad836e8958d157a10e9d48e66fe
parent3bc6f1d6afdabb28284450e96067382d744759e9 (diff)
Avoid possibly-unportable initializer, per buildfarm warning.
-rw-r--r--contrib/tsearch2/dict_thesaurus.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/contrib/tsearch2/dict_thesaurus.c b/contrib/tsearch2/dict_thesaurus.c
index cf3925f80c..d7c09aafba 100644
--- a/contrib/tsearch2/dict_thesaurus.c
+++ b/contrib/tsearch2/dict_thesaurus.c
@@ -696,11 +696,14 @@ thesaurus_init(PG_FUNCTION_ARGS)
static LexemeInfo *
findTheLexeme(DictThesaurus * d, char *lexeme)
{
- TheLexeme key = {lexeme, NULL}, *res;
+ TheLexeme key, *res;
if (d->nwrds == 0)
return NULL;
+ key.lexeme = lexeme;
+ key.entries = NULL;
+
res = bsearch(&key, d->wrds, d->nwrds, sizeof(TheLexeme), cmpLexemeQ);
if (res == NULL)