bugs on error codes