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

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

XMLWordPrintable

    • 2d
    • b15

      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.

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

              Created:
              Updated:
              Resolved: