diff options
-rw-r--r-- | src/main/javassist/CtClassType.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/javassist/CtClassType.java b/src/main/javassist/CtClassType.java index 7e965e56..f3106b9e 100644 --- a/src/main/javassist/CtClassType.java +++ b/src/main/javassist/CtClassType.java @@ -240,7 +240,7 @@ class CtClassType extends CtClass { } public synchronized void releaseClassFile() { - if (!isModified()) + if (classfile != null && !isModified() && hasMemberCache() == null) classfile = null; } @@ -256,7 +256,7 @@ class CtClassType extends CtClass { * of the CtClasses that have not been recently used * if they are unmodified. */ - private void releaseClassFiles() { + public void releaseClassFiles() { Enumeration e = classPool.classes.elements(); while (e.hasMoreElements()) { Object obj = e.nextElement(); |