]> granicus.if.org Git - postgresql/commit
Cleanup for some problems in tsearch patch:
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 25 Aug 2007 00:03:59 +0000 (00:03 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 25 Aug 2007 00:03:59 +0000 (00:03 +0000)
commit7351b5fa1781c3942d2d5ff2116d2d0ba882bd42
tree8b27ff0f6ef15b271ffbe644d4a934462a80f900
parentb918bf86c65632a5716308d8a613f5538a770927
Cleanup for some problems in tsearch patch:
- ispell initialization crashed on empty dictionary file
- ispell initialization crashed on affix file with prefixes but no suffixes
- stop words file was run through pg_verify_mbstr, with database
  encoding, but it's supposed to be UTF-8; similar bug for synonym files
- bunch of comments added, typos fixed, and other cleanup

Introduced consistent encoding checking/conversion of data read from tsearch
configuration files, by doing this in a single t_readline() subroutine
(replacing direct usages of fgets).  Cleaned up API for readstopwords too.

Heikki Linnakangas
14 files changed:
src/backend/snowball/dict_snowball.c
src/backend/tsearch/dict_ispell.c
src/backend/tsearch/dict_simple.c
src/backend/tsearch/dict_synonym.c
src/backend/tsearch/dict_thesaurus.c
src/backend/tsearch/spell.c
src/backend/tsearch/ts_locale.c
src/backend/tsearch/ts_parse.c
src/backend/tsearch/ts_utils.c
src/backend/tsearch/wparser.c
src/include/tsearch/dicts/spell.h
src/include/tsearch/ts_locale.h
src/include/tsearch/ts_public.h
src/include/tsearch/ts_utils.h