freebsd-ports/textproc/clucene/files/patch-src__contribs-lib__CLucene__snowball__SnowballAnalyzer.h
Jung-uk Kim fa023c7e1a - Implement efficient BitSet::nextSetBit() to reduce diff against upstream.
http://clucene.git.sourceforge.net/git/gitweb.cgi?p=clucene/clucene;a=commitdiff;h=17e53d7

- Fix a buffer overflow in CJKAnalyzer.  Somehow the upstream missed this
in 2.3.3.4 branch.

http://clucene.svn.sourceforge.net/viewvc/clucene?view=revision&revision=2630

- Fix potential memory leaks in libstemmer.  Merged from Snowball changes.

http://svn.tartarus.org/snowball/trunk/snowball/libstemmer/libstemmer_c.in?r1=409&r2=520&view=patch

- Implement SnowballAnalyzer::reusableTokenStream(). [1]  Also, this patch
fixes memory leaks found by the submitter.

Submitted by:	Kishore Ramareddy (kishore at niksun dot com)
		(initial version) [1]
Feature safe:	yes
2013-04-16 18:37:03 +00:00

19 lines
801 B
C++

--- src/contribs-lib/CLucene/snowball/SnowballAnalyzer.h.orig 2011-03-16 20:21:07.000000000 -0400
+++ src/contribs-lib/CLucene/snowball/SnowballAnalyzer.h 2013-04-01 18:25:10.000000000 -0400
@@ -22,6 +22,7 @@
class CLUCENE_CONTRIBS_EXPORT SnowballAnalyzer: public Analyzer {
TCHAR* language;
CLTCSetList* stopSet;
+ class SavedStreams;
public:
/** Builds the named analyzer with no stop words. */
@@ -37,6 +38,8 @@
StandardFilter}, a {@link LowerCaseFilter} and a {@link StopFilter}. */
TokenStream* tokenStream(const TCHAR* fieldName, CL_NS(util)::Reader* reader);
TokenStream* tokenStream(const TCHAR* fieldName, CL_NS(util)::Reader* reader, bool deleteReader);
+
+ TokenStream* reusableTokenStream(const TCHAR* fieldName, CL_NS(util)::Reader* reader);
};
CL_NS_END2