mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ulrich Kreher (JIRA)" <j...@apache.org>
Subject [jira] Updated: (DIRMINA-822) Deserialising classes that do not implement Serializable fails
Date Mon, 14 Mar 2011 15:13:29 GMT

     [ https://issues.apache.org/jira/browse/DIRMINA-822?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Ulrich Kreher updated DIRMINA-822:
----------------------------------

    Attachment: AbstractIoBuffer.patch

A rather simple patch but it works at least for our scenario.

> Deserialising classes that do not implement Serializable fails
> --------------------------------------------------------------
>
>                 Key: DIRMINA-822
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-822
>             Project: MINA
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.0.2
>            Reporter: Ulrich Kreher
>         Attachments: AbstractIoBuffer.patch
>
>
> AbstractIoBuffer uses ObjectStreamClass.lookup(Class) which returns null for classes
that do not implement Serializable. This in turn leads to a NullPointerException a few lines
below in resolveClass(ObjectStreamClass) where the ObjectStreamClass-parameter is null.
> Deserialising a non-serialisable class is completely legal, instances of such a class
will already fail to serialise so they will never get to deserialisation.
> Using ObjectStreamClass.lookupAny(Class) will solve this issue, but it is not available
before Java 6.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message