Throw an exception for unserialize() errors