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

REDO - System.loadLibrary cannot find library when path contains quoted entry

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 21
    • core-libs
    • None

      System.loadLibrary fails on Windows when path/java.library.path are of
      a certain format, e.g. individually quoted.

      On Windows PATH entries can be individually quoted (that's not necessary, but still possible).
      http://blogs.msdn.com/b/oldnewthing/archive/2006/09/29/776926.aspx

      Checking Windows command line shell confirms, it understands PATH correctly, whether its entries are quoted or not.

      The quoting of individual Windows PATH entries should be handled when the PATH
      environment variable is read. The Hotspot code in os_windows.cpp that reads PATH
      and creates java.libary.path should remove the quotes. This will allow the removal
      of the Windows specific quote handling and simplify splitting the java.library.path
      and other similar paths.

      There is no need to protect the Window path separator ";", as it has not been a problem.
      The semi-colon does not appear to be used in Windows paths, though it is an allow character in file and directory names.

            rriggs Roger Riggs
            rriggs Roger Riggs
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: