mirror of https://github.com/postgres/postgres
Avoid possibly-unportable initializer, per buildfarm warning.
This commit is contained in:
parent
84a0445c4d
commit
a190eb3d7d
|
@ -1,4 +1,4 @@
|
||||||
/* $PostgreSQL: pgsql/contrib/tsearch2/dict_thesaurus.c,v 1.8 2007/02/01 19:10:23 momjian Exp $ */
|
/* $PostgreSQL: pgsql/contrib/tsearch2/dict_thesaurus.c,v 1.9 2007/07/15 22:57:48 tgl Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* thesaurus
|
* thesaurus
|
||||||
|
@ -696,11 +696,14 @@ thesaurus_init(PG_FUNCTION_ARGS)
|
||||||
static LexemeInfo *
|
static LexemeInfo *
|
||||||
findTheLexeme(DictThesaurus * d, char *lexeme)
|
findTheLexeme(DictThesaurus * d, char *lexeme)
|
||||||
{
|
{
|
||||||
TheLexeme key = {lexeme, NULL}, *res;
|
TheLexeme key, *res;
|
||||||
|
|
||||||
if (d->nwrds == 0)
|
if (d->nwrds == 0)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
key.lexeme = lexeme;
|
||||||
|
key.entries = NULL;
|
||||||
|
|
||||||
res = bsearch(&key, d->wrds, d->nwrds, sizeof(TheLexeme), cmpLexemeQ);
|
res = bsearch(&key, d->wrds, d->nwrds, sizeof(TheLexeme), cmpLexemeQ);
|
||||||
|
|
||||||
if (res == NULL)
|
if (res == NULL)
|
||||||
|
|
Loading…
Reference in New Issue