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

ISE "zip file closed" from JarURLConnection.getInputStream on JDK 7 when !useCaches

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b146
    • CPU:
      generic, x86
    • OS:
      generic, linux
    • Verification:
      Verified

      Description

      Compile and run the class given in http://netbeans.org/bugzilla/attachment.cgi?id=108629 using JDK 6. It prints

      class Bug196716

      as expected. Now run using JDK 7 b143; it throws

      Exception in thread "main" java.lang.IllegalStateException: zip file closed
      at java.util.zip.ZipFile.ensureOpen(ZipFile.java:632)
      at java.util.zip.ZipFile.getInputStream(ZipFile.java:345)
      at java.util.jar.JarFile.getInputStream(JarFile.java:403)
      at sun.net.www.protocol.jar.JarURLConnection.getInputStream(JarURLConnection.java:162)
      at sun.misc.URLClassPath$Loader$1.getInputStream(URLClassPath.java:553)
      at sun.misc.Resource.cachedInputStream(Resource.java:77)
      at sun.misc.Resource.getByteBuffer(Resource.java:160)
      at java.net.URLClassLoader.defineClass(URLClassLoader.java:436)
      at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
      at Bug196716.main(Bug196716.java:36)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              michaelm Michael McMahon
              Reporter:
              jglick Jesse Glick (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: