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

"java.util.zip.ZipException: The system cannot find the file specified"

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 7
    • 1.4.0, 1.4.2, 1.4.2_03, 5.0
    • core-libs
    • None
    • b64
    • generic, x86, sparc
    • generic, solaris_9, windows_xp

      When one invokes java with a wrong file name like this:

        $ java -jar nosuchfile.jar

      You get:

      java.util.zip.ZipException: The system cannot find the file specified
              at java.util.zip.ZipFile.open(Native Method)
              at java.util.zip.ZipFile.<init>(ZipFile.java:112)
              at java.util.jar.JarFile.<init>(JarFile.java:127)
              at java.util.jar.JarFile.<init>(JarFile.java:65)

      This also happens with programatic invocation of new JarFile(...);
      But as you see it doesn't actually print the file name, which makes the debugging unnecessarily hard.
      ###@###.### 2004-04-15

            sherman Xueming Shen
            kkawagucsunw Kohsuke Kawaguchi (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: