(fs) CopyMoveHelper.copyToForeignTarget use of sourcePosixView is confusing

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: 21, 25
    • Component/s: core-libs
    • generic
    • generic

      ADDITIONAL SYSTEM INFORMATION :
      Windows, Java 21

      A DESCRIPTION OF THE PROBLEM :
      shouldn't linkOptions be used in reading the PosixFileAttributeView too ?

              final PosixFileAttributeView sourcePosixView =
                  Files.getFileAttributeView(source, PosixFileAttributeView.class);

              // attributes of source file
              BasicFileAttributes sourceAttrs = null;
              if (sourcePosixView != null) {
                  try {
                      sourceAttrs = Files.readAttributes(source,
                                                         PosixFileAttributes.class,
                                                         linkOptions);
                  } catch (SecurityException ignored) {
                      // okay to continue if RuntimePermission("accessUserInformation") not granted
                  }
              }



            Assignee:
            Brian Burkhalter
            Reporter:
            Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: