From 2fd0f7b21d98593d440ed5bff1c4ab5d1ef0a436 Mon Sep 17 00:00:00 2001 From: nobounce Date: Tue, 3 Oct 2023 13:32:28 +0200 Subject: [PATCH] Don't pass int by reference --- src/btop.cpp | 2 +- src/btop_config.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/btop.cpp b/src/btop.cpp index e53ec020e..382b72fe8 100644 --- a/src/btop.cpp +++ b/src/btop.cpp @@ -111,7 +111,7 @@ namespace Global { } //* A simple argument parser -void argumentParser(const int& argc, char **argv) { +void argumentParser(const int argc, char **argv) { for(int i = 1; i < argc; i++) { const string argument = argv[i]; if (is_in(argument, "-h", "--help")) { diff --git a/src/btop_config.hpp b/src/btop_config.hpp index e5f4ac1b6..005dcbfd1 100644 --- a/src/btop_config.hpp +++ b/src/btop_config.hpp @@ -88,7 +88,7 @@ namespace Config { } //* Set config key to int - inline void set(const std::string_view name, const int& value) { + inline void set(const std::string_view name, const int value) { if (_locked(name)) intsTmp.insert_or_assign(name, value); else ints.at(name) = value; }