commit: Improve treatment of expected bugs.