Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-3831

Passing a null fieldname to MemoryFields#terms in MemoryIndex throws a NPE

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 4.0-ALPHA
    • Fix Version/s: 3.6, 4.0-ALPHA
    • Component/s: core/index
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      I found this when querying a MemoryIndex using a RegexpQuery wrapped by a SpanMultiTermQueryWrapper. If the regexp doesn't match anything in the index, it gets rewritten to an empty SpanOrQuery with a null field value, which then triggers the NPE.

        Attachments

        1. LUCENE-3831.patch
          9 kB
          Michael McCandless
        2. TestNullFieldAfterRegexpRewrite.java
          2 kB
          Alan Woodward
        3. mindex-null-field.patch
          0.6 kB
          Alan Woodward

          Activity

            People

            • Assignee:
              mikemccand Michael McCandless
              Reporter:
              romseygeek Alan Woodward
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: