Index: ModuleInstallerSupport.java =================================================================== RCS file: /usr/local/tigris/data/helm/cvs/repository/core/src/org/netbeans/core/Attic/ModuleInstallerSupport.java,v --- ModuleInstallerSupport.java 2001/04/25 15:42:21 1.15.2.2 +++ ModuleInstallerSupport.java 2001/09/19 16:18:04 @@ -415,6 +415,18 @@ if (! mi.isUpdated ()) ModuleInstaller.err.log (ErrorManager.WARNING, "WARNING - module will not really be updated"); int kind = getKind (existing); remove (existing, kind); + Collection dependents = getDependentModules(mi.getDescription(), ENABLED_MODULE); + if (! dependents.isEmpty()) { + // #15599: there may have been other modules dependent on this, and it may + // happen that they kept the old bogus classloader as a parent. Clear them, + // else they could poison the system classloader with the old loader. + ModuleInstaller.err.log("Fixing #15599 for " + mi.getDescription().getCodeNameBase() + " with dependents " + dependents); + Iterator it = dependents.iterator(); + while (it.hasNext()) { + ModuleItem dep = (ModuleItem)it.next(); + dep.getDescription().setClassLoader(null); + } + } add (mi, kind); } } else if (ghost != null) { // #9806