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

Silly array comparison in GaloisCounterMode.overlapDetection

XMLWordPrintable

      SonarCloud reports:
        Use "Arrays.equals(array1, array2)" or the "==" operator instead of using the "Object.equals(Object obj)" method.

              } else if (!src.isDirect() && !dst.isDirect()) {
                  if (!src.isReadOnly()) {
                      // If using the heap, check underlying byte[] address.
                      if (!src.array().equals(dst.array()) ) { // <--- here

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

              Created:
              Updated:
              Resolved: