7080289: AWTKeystroke class registers a subclass factory during deserialization
Reviewed-by: serb
--- a/jdk/src/share/classes/java/awt/AWTKeyStroke.java Mon Sep 26 17:59:52 2011 +0400
+++ b/jdk/src/share/classes/java/awt/AWTKeyStroke.java Mon Sep 26 18:18:29 2011 +0400
@@ -777,10 +777,6 @@
*/
protected Object readResolve() throws java.io.ObjectStreamException {
synchronized (AWTKeyStroke.class) {
- Class newClass = getClass();
- if (!newClass.equals(ctor.getDeclaringClass())) {
- registerSubclass(newClass);
- }
return getCachedStroke(keyChar, keyCode, modifiers, onKeyRelease);
}
}