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

MathUtil is publiuc and checks parameter only with assert. Incorrect usage can easily lead to endless loop

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 4.0-ALPHA, 6.0
    • Fix Version/s: 4.0-ALPHA, 6.0
    • Component/s: core/other
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      We should check the 2 parameters carefully before entering the loop. Those checks here cost nothing.

      Otherwise this class must be hidden, we should not offer any public method to the users that can loop infinite without parameter checking.

        Attachments

        1. LUCENE-4162.patch
          0.7 kB
          Uwe Schindler

          Activity

            People

            • Assignee:
              uschindler Uwe Schindler
              Reporter:
              uschindler Uwe Schindler
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: