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

UnescapedCharSequence.toLowerCase throws ArrayIndexOutOfBoundsException for certain input strings

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Patch Available
    • Minor
    • Resolution: Unresolved
    • 5.0
    • None
    • modules/queryparser
    • None
    • New, Patch Available

    Description

      The static toLowerCase-method of UnescapedCharSequence does not account for locales in which the length of the result of String.toLowerCase is not the same as the length of the input string. This causes an ArrayIndexOutOfBoundsException, because wasEscaped and the chars array are not of the same length.
      (See attached test and patch)

      Attachments

        1. LUCENE-6358-fix.patch
          2 kB
          Christoph Kaser
        2. LUCENE-6358-test.patch
          2 kB
          Christoph Kaser

        Activity

          People

            Unassigned Unassigned
            christophk Christoph Kaser
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: