Error display and error-checked malloc()