Add marshaling support for Error messages