Protect against malformed URLs on Windows
Update JarFile to correctly create system independent URLs to prevent potential URISyntaxExceptions when running on Windows. Fixes gh-836
This commit is contained in:
@@ -92,7 +92,6 @@ public class JarFileTests {
|
||||
assertThat(urlClassLoader.getResource("special/\u00EB.dat"), notNullValue());
|
||||
assertThat(urlClassLoader.getResource("d/9.dat"), notNullValue());
|
||||
jarFile.close();
|
||||
urlClassLoader.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -135,7 +134,6 @@ public class JarFileTests {
|
||||
URLClassLoader urlClassLoader = new URLClassLoader(
|
||||
new URL[] { this.jarFile.getUrl() });
|
||||
assertThat(urlClassLoader.getResource("special/\u00EB.dat"), notNullValue());
|
||||
urlClassLoader.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user