Ensure that an invalid run terminates the line.