From: Zbigniew Jędrzejewski-Szmek Date: Sun, 21 Feb 2021 20:29:00 +0000 (+0100) Subject: core: minor simplification X-Git-Tag: v249-rc1~302^2~8 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=431733b866f184527649996193874885ac059b70;p=thirdparty%2Fsystemd.git core: minor simplification --- diff --git a/src/core/main.c b/src/core/main.c index 2f36d752bca..12948ca964c 100644 --- a/src/core/main.c +++ b/src/core/main.c @@ -2549,18 +2549,16 @@ static void setup_console_terminal(bool skip_setup) { static bool early_skip_setup_check(int argc, char *argv[]) { bool found_deserialize = false; - int i; /* Determine if this is a reexecution or normal bootup. We do the full command line parsing much later, so * let's just have a quick peek here. Note that if we have switched root, do all the special setup things * anyway, even if in that case we also do deserialization. */ - for (i = 1; i < argc; i++) { + for (int i = 1; i < argc; i++) if (streq(argv[i], "--switched-root")) return false; /* If we switched root, don't skip the setup. */ else if (streq(argv[i], "--deserialize")) found_deserialize = true; - } return found_deserialize; /* When we are deserializing, then we are reexecuting, hence avoid the extensive setup */ }