Index: src/main/java/javax/activation/MailcapCommandMap.java =================================================================== --- src/main/java/javax/activation/MailcapCommandMap.java (revision 21721) +++ src/main/java/javax/activation/MailcapCommandMap.java (working copy) @@ -605,6 +605,11 @@ // if anything goes wrong, do it the old way cl = Class.forName(name); } + if (!DataContentHandler.class.isAssignableFrom(cl)) { + if (LogSupport.isLoggable()) + LogSupport.log("DCH " + name + " is of invalid type"); + return null; + } if (cl != null) // XXX - always true? return (DataContentHandler)cl.newInstance(); } catch (IllegalAccessException e) {