From 87e7c430329211ba7f9c26befd7c97a7e6438dc5 Mon Sep 17 00:00:00 2001 From: Redkale <8730487+redkale@users.noreply.github.com> Date: Tue, 12 Feb 2019 11:52:23 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DJDK9+=E4=BB=A5=E4=B8=8ARedkal?= =?UTF-8?q?eClassLoader=E7=9A=84getAllURLS=E6=96=B9=E6=B3=95=E4=B8=AD?= =?UTF-8?q?=E7=9A=84BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/org/redkale/util/RedkaleClassLoader.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/org/redkale/util/RedkaleClassLoader.java b/src/org/redkale/util/RedkaleClassLoader.java index fac16801b..570823cf1 100644 --- a/src/org/redkale/util/RedkaleClassLoader.java +++ b/src/org/redkale/util/RedkaleClassLoader.java @@ -39,9 +39,9 @@ public class RedkaleClassLoader extends URLClassLoader { HashSet set = new HashSet<>(); String appPath = System.getProperty("java.class.path"); if (appPath != null && !appPath.isEmpty()) { - for (String path : appPath.replace(":/", "&&").replace(":\\", "##").replace(':', ';').split(";")) { + for (String path : appPath.replace("://", "&&").replace(":\\", "##").replace(':', ';').split(";")) { try { - set.add(Paths.get(path.replace("&&", ":/").replace("##", ":\\")).toRealPath().toFile().toURI().toURL()); + set.add(Paths.get(path.replace("&&", "://").replace("##", ":\\")).toRealPath().toFile().toURI().toURL()); } catch (Exception e) { } }