[jira] [Created] (LUCENE-3779) An incomplete fix for the NPE bugs in MultipleTermPositions.java
An incomplete fix for the NPE bugs in MultipleTermPositions.java Key: LUCENE-3779 URL: https://issues.apache.org/jira/browse/LUCENE-3779 Project: Lucene - Java Issue Type: Bug Components: core/index Affects Versions: 3.0 Reporter: Guangtai Liang Priority: Critical The fix revision 219387 was aimed to remove an NPE bug on the return value of _termPositionsQueue.peek() in the method skipTo of the file /lucene/java/trunk/src/java/org/apache/lucene/index/MultipleTermPositions.java , but it is incomplete. Since the returned value _termPositionsQueue.peek() could be null during the run-time execution, its value should also be null-checked before being dereferenced in other methods. The buggy code locations the same fix needs to be applied at are as bellows: Line 118, 124, 135 of the method next() : public final boolean next() throws IOException { if (_termPositionsQueue.size() == 0) return false; _posList.clear(); [Line 118]_doc = _termPositionsQueue.peek().doc(); TermPositions tp; do { tp = _termPositionsQueue.peek(); [Line 124]for (int i = 0; i tp.freq(); i++) { // NOTE: this can result in dup positions being added! _posList.add(tp.nextPosition()); } if (tp.next()) _termPositionsQueue.updateTop(); else { _termPositionsQueue.pop(); tp.close(); } [Line 135]} while (_termPositionsQueue.size() 0 _termPositionsQueue.peek().doc() == _doc); _posList.sort(); _freq = _posList.size(); return true; } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Created] (LUCENE-3780) An incomplete fix for the NPE bugs in ParallelReader.java
An incomplete fix for the NPE bugs in ParallelReader.java - Key: LUCENE-3780 URL: https://issues.apache.org/jira/browse/LUCENE-3780 Project: Lucene - Java Issue Type: Bug Components: core/index Affects Versions: 3.0 Reporter: Guangtai Liang Priority: Critical The fix revision 407851 was aimed to remove an NPE bug on the return value of fieldToReader.get(field) in the methods getTermFreqVector, hasNorms, norms, doSetNorm of the file /lucene/java/trunk/src/java/org/apache/lucene/index/ParallelReader.java , but it is incomplete. Since the returned value fieldToReader.get(field) could be null during the runtime execution, its value should also be null-checked before being dereferenced in other methods. The buggy code locations the same fix needs to be applied at are as bellows: Line 499 of the method ParallelTermEnum() : public ParallelTermEnum() throws IOException { try { field = fieldToReader.firstKey(); } catch(NoSuchElementException e) { // No fields, so keep field == null, termEnum == null return; } if (field != null) [Line 499]termEnum = fieldToReader.get(field).terms(); } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Created] (LUCENE-3781) Another incomplete fix for the NPE bugs in ParallelReader.java
Another incomplete fix for the NPE bugs in ParallelReader.java -- Key: LUCENE-3781 URL: https://issues.apache.org/jira/browse/LUCENE-3781 Project: Lucene - Java Issue Type: Bug Components: core/index Affects Versions: 3.0 Reporter: Guangtai Liang The fix revision 407851 was aimed to remove an NPE bug on the value of termDocs in the methods next, read, skipTo, close of the file /lucene/java/trunk/src/java/org/apache/lucene/index/ParallelReader.java , but it is incomplete. Since the value termDocs could be null during the runtime execution, its value should also be null-checked before being dereferenced in other methods. The buggy code locations the same fix needs to be applied at are as bellows: Line 574, 575 of the methods doc() , and freq: public int doc() { return termDocs.doc(); } public int freq() { return termDocs.freq(); } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Created] (LUCENE-3782) An incomplete fix for the NPE bugs in Directory.java
An incomplete fix for the NPE bugs in Directory.java Key: LUCENE-3782 URL: https://issues.apache.org/jira/browse/LUCENE-3782 Project: Lucene - Java Issue Type: Bug Components: core/store Affects Versions: 3.0 Reporter: Guangtai Liang Priority: Critical The fix revision 499089 was aimed to remove an NPE bug (LUCENE-773) on the value of lockFactory in the method clearLock of the file /lucene/java/trunk/src/java/org/apache/lucene/store/Directory.java , but it is incomplete. Since the value lockFactory could be null during the runtime execution, its value should also be null-checked before being dereferenced in other methods. The buggy code locations the same fix needs to be applied at are as bellows: Line 106 of the methods doc() , and freq: public Lock makeLock(String name) { [Line 106] return lockFactory.makeLock(name); } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Created] (LUCENE-3783) An incomplete fix for the NPE bugs in NearSpansUnordered.java
An incomplete fix for the NPE bugs in NearSpansUnordered.java - Key: LUCENE-3783 URL: https://issues.apache.org/jira/browse/LUCENE-3783 Project: Lucene - Java Issue Type: Bug Components: core/search Affects Versions: 3.0 Reporter: Guangtai Liang The fix revision 698487 was aimed to remove an NPE bug (LUCENE-1404) on the returned value of min() in the method isPayloadAvailable of the file /lucene/java/trunk/src/java/org/apache/lucene/search/spans/NearSpansUnordered.java , but it is incomplete. Since the returned value min() could be null during the runtime execution, its value should also be null-checked before being dereferenced in other methods. The buggy code locations the same fix needs to be applied at are as bellows: Lines 159 , 170 , and 196 of the methods next() Line 216 of the methods skipTo() Line 230 of the methods doc() 230 public int doc() { return min().doc(); } Line 232 of the methods start() 232 public int start() { return min().start(); } Line 315 of the methods atMatch() private boolean atMatch() { 315return (min().doc() == max.doc()) ((max.end() - min().start() - totalLength) = slop); } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org