RFR: 8338626: ClassLoaderExt::process_jar_manifest() should allow / separator on Windows [v4]

Alan Bateman alanb at openjdk.org
Fri Sep 13 08:16:06 UTC 2024


On Fri, 13 Sep 2024 07:35:44 GMT, Ioi Lam <iklam at openjdk.org> wrote:

>> Just to repeat what I said previously, the value of Class-Path attribute is a sequence of relative URLs. The code in ClassLoaderExt::process_jar_manifest will work for some cases but in general, the appending used in this function can't be worked to combine a file path and URL path.
>
> Alan, could you show us some cases where ClassLoaderExt::process_jar_manifest() will fail. IIUC, the failures won't be Windows-specific (i.e., orthogonal to the \ vs / issues in this bug) but rather will happen on all platforms.

Can you try examples like `file:lib.jar`, `file:/d/lib.jar`, `/d/lib.jar` for starters. Once you bring Windows file paths into the picture then it's a world of hurt. There is big other topic around escaping where Class-Path is completely broken and we haven't figure out how to fix these issues in a compatibility way.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/20924#discussion_r1758401444


More information about the hotspot-runtime-dev mailing list