Fixed portable serialization issues.