]> source.dussan.org Git - javassist.git/commitdiff
fixed JASSIST-56
authorchiba <chiba@30ef5769-5b8d-40dd-aea6-55b5d6557bb3>
Wed, 19 Mar 2008 19:06:05 +0000 (19:06 +0000)
committerchiba <chiba@30ef5769-5b8d-40dd-aea6-55b5d6557bb3>
Wed, 19 Mar 2008 19:06:05 +0000 (19:06 +0000)
git-svn-id: http://anonsvn.jboss.org/repos/javassist/trunk@430 30ef5769-5b8d-40dd-aea6-55b5d6557bb3

src/main/javassist/bytecode/annotation/Annotation.java

index a2cef9a7c9dc56c08319735689aacf37f613df24..1156a460c60c50e27a42014bcc1cd816c2a229d4 100644 (file)
@@ -332,10 +332,15 @@ public class Annotation {
         if (getTypeName().equals(other.getTypeName()) == false)
             return false;
 
-        if (members == null && other.members != null)
-           return false;
-        if (members != null && other.members == null)
-           return false;
-        return members.equals(other.members);
+        HashMap otherMembers = other.members;
+        if (members == otherMembers)
+            return true;
+        else if (members == null)
+            return otherMembers == null;
+        else
+            if (otherMembers == null)
+                return false;
+            else
+                return members.equals(otherMembers);
     }
 }