From ba050c112e41afb2fc7bfa603257940acb14790e Mon Sep 17 00:00:00 2001 From: Kevin Caccamo Date: Mon, 16 Jun 2025 03:05:28 -0400 Subject: [PATCH] Remove useless if statement If conf is at eof, linePos and command.Size() will be 0, and the other statements will not run due to eof checks and pointer checks --- src/gamedata/keysections.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/gamedata/keysections.cpp b/src/gamedata/keysections.cpp index ca37e5017..763d5331f 100644 --- a/src/gamedata/keysections.cpp +++ b/src/gamedata/keysections.cpp @@ -183,10 +183,6 @@ void D_LoadWadSettings () { command.Push(conf[linePos]); } - if (linePos == 0 && conf >= eof) // End of file - { - break; - } // Increment 'conf' pointer to next line conf += linePos; while (conf < eof && (*conf == '\n' || *conf == '\r'))