Fix build failure detection.