Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8263981

java.awt.image.ComponentSampleModel equals/hashcode use numBands twice

    XMLWordPrintable

Details

    • 2d
    • b15

    Description

      SonarCloud reports the problem in ComponentSampleModel.equals:
        Correct one of the identical sub-expressions on both sides of operator "&&"

      ...near "this.numBands == that.numBands". It is checked twice. hashCode also processes it twice.

      Attachments

        Issue Links

          Activity

            People

              shade Aleksey Shipilev
              shade Aleksey Shipilev
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: