return object;
}
catch (Exception e)
{
pendingException = e;
throw new FacesException(e);
}
finally
{
if (s != null)
{
try
{
s.close();
}
catch (IOException e)
{
// If a previous exception is thrown
// ignore this, but if not, wrap it in a
// FacesException and throw it. In this way
// we preserve the original semantic of this
// method, but we handle correctly the case
// when we close a stream. Obviously, the
// information about this exception is lost,
// but note that the interesting information
// is always on pendingException, since we
// only do a readObject() on the outer try block.
if (pendingException == null)
{
throw new FacesException(e);
}
}
finally
{
s = null;