From 9f924f37fbfb32c2450ef0109914369f9b10b04e Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Sun, 15 Nov 2020 11:25:45 +0100 Subject: [PATCH] reader: Pre-increment If we don't do it now, static analysis things are just gonna bug us until someone does it. --- src/reader.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/reader.cpp b/src/reader.cpp index 74054d1d6..934fc09da 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -2584,7 +2584,7 @@ static int read_i(parser_t &parser) { data->import_history_if_necessary(); while (!check_exit_loop_maybe_warning(data.get())) { - run_count++; + ++run_count; maybe_t tmp = data->readline(0); if (tmp && !tmp->empty()) { @@ -2597,7 +2597,7 @@ static int read_i(parser_t &parser) { auto eval_res = reader_run_command(parser, command); signal_clear_cancel(); if (!eval_res.no_status) { - status_count++; + ++status_count; } // If the command requested an exit, then process it now and clear it.