DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21189>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21189
Hits.length() returns to large value
Summary: Hits.length() returns to large value
Product: Lucene
Version: unspecified
Platform: Other
OS/Version: Other
Status: NEW
Severity: Normal
Priority: Other
Component: Search
AssignedTo: lucene-dev@jakarta.apache.org
ReportedBy: luetzken@itaw.hu-berlin.de
Hits hits = searcher.search(...);
for(int i = 0; i < hits.length(); ++i) {
int x = hits.id(i);
...
}
throws java.lang.ArrayIndexOutOfBoundsException: 100 >= 100
I think that means hits.length() returns an in valid value 101.
After a first look the reason could be the initialization of the hitcounter
in IndexSearcher.search(Query, Filter, int). There the counter is set to 1
and than incremented for every hit. Hits value will then be propagated to
Hits.length.
I'm working with lucene 1.3 RC1
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-dev-help@jakarta.apache.org
|