Fix bug on error path removal

1st error caused the 2nd error during cleanup, which obfuscated the 1st
error.