Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-14783

Fix array comparison in SnapshotAdapter

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 5.9.4
    • Fix Version/s: 5.9.5
    • Component/s: Publishing

      Description

      The following code can raise a NPE

          protected static boolean compareArrays(String[] arr1, String[] arr2) {
              HashSet<String> set1 = new HashSet<String>(Arrays.asList(arr1));
              HashSet<String> set2 = new HashSet<String>(Arrays.asList(arr2));
              return set1.equals(set2);
          }
      

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: