Name: md23716 Date: 03/21/2001
OS: -Discovered on Windows2000, but affects All Platforms
JDK: 1.3.1-rc1-b19
Related Sunbugs #'s: 4273532, 4294586
The inital problem manifested itself when a class file was located in a
directory with a '#' in its title (i.e. c:\a#b). When running the program
(by issuing java <classname>) an exception is thrown:
Exception in thread "main" java.lang.NoClassDefFoundError
This problem was fixed as described in Bug ID 4273532 and 4294586. However,
the changes made in this fix potentially affect numerous other files. The
reason for this is because when a URL is instantiated it encodes a file's
pathname in order to escape reserved URL characters. Thereafter any call to
URL.getFIle() would return an encoded version of the path. I believe the
orginal fix may have accounted for some of these scenario's, but others
have been overlooked. For example ExtCheck.java has a call to URL.getFile()
and at this stage the returned String should be decoded with a call to
ParseUtil.decode(). Because this call is missing the original problem is
reinstated when using the extcheck tool.
To recreate this problem perform the following steps:
1. Create a directory with a '#' in its title. i.e. mkdir a#b
2. Copy/Create a Jar file in this directory
3. Run ExtCheck on this Jar file i.e extcheck <name of jar>.jar
4. Receive following exception:
IO Exception occurred
This is just one scenario where a call to URL.getFile() should be decoded,
there are numerous other that need to be looked into in order to complete
the fix detailed in the aforementioned sunbugs.
======================================================================
- duplicates
-
JDK-4416056 Application requesting JRE 1.4.0-beta could not be launched (B58)
-
- Closed
-