Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recent Changes to DocReconstructor sometimes cause Null Ref #17

Closed
GoogleCodeExporter opened this issue Feb 2, 2016 · 2 comments
Closed

Comments

@GoogleCodeExporter
Copy link

The DocReconstructor sometimes results in a Null Reference Exception.  The
problematic line is line 142 (svn trunk, 4/8/10):
     if (te == null || !te.term().field().equals(fld)) {

This line should be changes to:
      if (te == null || te.term() == null || !te.term().field().equals(fld)) {

Apparently, it is somehow possible to have a TermEnum here with a null
term.  I have seen this in several indexes, though I don't know the exact
scenario which reproduces an index which would cause this error.  The
indexes I've seen which cause this were created with Solr 1.4 (using Lucene
2.9.2).

Original issue reported on code.google.com by solrt...@gmail.com on 9 Apr 2010 at 3:55

@GoogleCodeExporter
Copy link
Author

Thanks for finding this. I can confirm that compiling 1.0.1 with this patch 
solves the nullpointers when reconstructing documents with NO_NORMS or null 
terms (using Lucene 3.0.3)

Original comment by mtone...@gmail.com on 7 Feb 2011 at 2:35

@GoogleCodeExporter
Copy link
Author

I applied this patch to branch-3x in rev. 57. This problem doesn't affect the 
trunk where enumerators behave differently. Thank you!

Original comment by sig...@gmail.com on 27 Apr 2011 at 10:25

  • Changed state: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant