Fix for Bug 347578 - [OTRE] JVM hang while loading class sun.misc.Cleaner
diff --git a/plugins/org.eclipse.objectteams.runtime/src/org/eclipse/objectteams/otre/jplis/ObjectTeamsTransformer.java b/plugins/org.eclipse.objectteams.runtime/src/org/eclipse/objectteams/otre/jplis/ObjectTeamsTransformer.java
index 419019e..9b0ea13 100644
--- a/plugins/org.eclipse.objectteams.runtime/src/org/eclipse/objectteams/otre/jplis/ObjectTeamsTransformer.java
+++ b/plugins/org.eclipse.objectteams.runtime/src/org/eclipse/objectteams/otre/jplis/ObjectTeamsTransformer.java
@@ -106,12 +106,23 @@
 			ProtectionDomain protectionDomain, byte[] classfileBuffer)
 			throws IllegalClassFormatException
 	{
-		if (   className.startsWith("org/eclipse/objectteams/otre")
-			|| className.startsWith("org/apache/bcel")
-			|| className.equals("java/util/LinkedHashMap$KeyIterator")) // saw class loading circularity caused by accessing this class
-		{
-			// skip OTRE and BCEL classes
-			return null;
+		switch(className.charAt(0)) {
+		case 'o':
+			if (   className.startsWith("org/eclipse/objectteams/otre")
+				|| className.startsWith("org/apache/bcel"))
+				// skip OTRE and BCEL classes
+				return null;
+			break;
+		case 's':
+			if (className.startsWith("sun/misc"))
+				// skip, I saw a mysterious deadlock involving sun.misc.Cleaner
+				return null;
+			break;
+		case 'j':
+			if (className.equals("java/util/LinkedHashMap$KeyIterator")) 
+				// skip, I saw class loading circularity caused by accessing this class
+				return null;
+			break;
 		}
 		if (classBeingRedefined != null) {
 			System.out.println("Redefinition!");