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

jdk/test/lib/FileInstaller throws NPE if dst is in current directory

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b126

      Description

      working on JDK-8158184, I noticed that "jdk.test.lib.FileInstaller A A" leads to NPE:

      java.lang.NullPointerException
              at jdk.test.lib.FileInstaller.main(FileInstaller.java:55)
              at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(java.base@9-internal/Native Method)
              at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(java.base@9-internal/NativeMethodAccessorImpl.java:62)
              at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(java.base@9-internal/DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(java.base@9-internal/Method.java:531)
              at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:110)
              at java.lang.Thread.run(java.base@9-internal/Thread.java:843)


      this happens because Path dstDir = dst.getParent() will be null, if dst is in the current directory.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                iignatyev Igor Ignatyev
                Reporter:
                iignatyev Igor Ignatyev
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: