Fix concurrent errors in URLClassLoaderAccess (#3403)

This commit is contained in:
OOP-778 2022-09-05 23:39:52 +03:00 committed by GitHub
parent a2e4a81e29
commit 1790c0ad47
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -167,10 +167,12 @@ public abstract class URLClassLoaderAccess {
URLClassLoaderAccess.throwError(new NullPointerException("unopenedURLs or pathURLs"));
}
synchronized (this.unopenedURLs) {
this.unopenedURLs.add(url);
this.pathURLs.add(url);
}
}
}
private static class Noop extends URLClassLoaderAccess {
private static final Noop INSTANCE = new Noop();