diff options
author | Burak Şahin <abrkshn95@gmail.com> | 2021-09-21 11:13:48 +0300 |
---|---|---|
committer | Burak Şahin <abrkshn95@gmail.com> | 2021-09-21 11:13:48 +0300 |
commit | 018169818c4ed96d3095f52c588b439510c1b288 (patch) | |
tree | bd150ee8217d1a822fdc4a202af048523bdf2ea8 /src/main/javassist/CtClass.java | |
parent | 047f7c71be30d1fce5773c8e9c014052acac14df (diff) | |
download | javassist-018169818c4ed96d3095f52c588b439510c1b288.tar.gz javassist-018169818c4ed96d3095f52c588b439510c1b288.zip |
Fix for NullPointerException on detach()
Diffstat (limited to 'src/main/javassist/CtClass.java')
-rw-r--r-- | src/main/javassist/CtClass.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/javassist/CtClass.java b/src/main/javassist/CtClass.java index f227019f..f1a47342 100644 --- a/src/main/javassist/CtClass.java +++ b/src/main/javassist/CtClass.java @@ -1423,7 +1423,7 @@ public abstract class CtClass { public void detach() { ClassPool cp = getClassPool(); CtClass obj = cp.removeCached(getName()); - if (obj != this) + if (obj != null && obj != this) cp.cacheCtClass(getName(), obj, false); } |