Fix handling of unexpected failures in subunithelper.