Fix return value to contain failure information.