summaryrefslogtreecommitdiff
path: root/Shell
diff options
context:
space:
mode:
authorShannon Booth <shannon.ml.booth@gmail.com>2020-03-22 10:14:12 +1300
committerAndreas Kling <kling@serenityos.org>2020-03-22 01:15:33 +0100
commitd806dfe801bb47ed62b50501ce8b5954d4baded8 (patch)
treead02f05be89fe5d65a476f7a543938eb293c96c9 /Shell
parentec6e55cfc630bbd089875b0e3fd6536013789399 (diff)
downloadserenity-d806dfe801bb47ed62b50501ce8b5954d4baded8.zip
Shell: Use size_t for SH_DEBUG vector iteration
We missed this when switching to size_t for vector sizing as this code is not normally compiled.
Diffstat (limited to 'Shell')
-rw-r--r--Shell/main.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Shell/main.cpp b/Shell/main.cpp
index 5e8877a563..cf7f330666 100644
--- a/Shell/main.cpp
+++ b/Shell/main.cpp
@@ -755,15 +755,15 @@ static int run_command(const String& cmd)
#ifdef SH_DEBUG
for (auto& command : commands) {
- for (int i = 0; i < command.subcommands.size(); ++i) {
- for (int j = 0; j < i; ++j)
+ for (size_t i = 0; i < command.subcommands.size(); ++i) {
+ for (size_t j = 0; j < i; ++j)
dbgprintf(" ");
for (auto& arg : command.subcommands[i].args) {
dbgprintf("<%s> ", arg.characters());
}
dbgprintf("\n");
for (auto& redirecton : command.subcommands[i].redirections) {
- for (int j = 0; j < i; ++j)
+ for (size_t j = 0; j < i; ++j)
dbgprintf(" ");
dbgprintf(" ");
switch (redirecton.type) {