Skip to content

Commit ed18c2a

Browse files
YHNdnzjbluca
authored andcommitted
core/main: also check the argument terminator
For future-proof reasons, in case we will add another option that starts with --deserialize. Addresses systemd/systemd@4f44d2c#r107285603 (cherry picked from commit 09567df)
1 parent 4f4e0ba commit ed18c2a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2704,7 +2704,7 @@ static bool early_skip_setup_check(int argc, char *argv[]) {
27042704
for (int i = 1; i < argc; i++)
27052705
if (streq(argv[i], "--switched-root"))
27062706
return false; /* If we switched root, don't skip the setup. */
2707-
else if (startswith(argv[i], "--deserialize"))
2707+
else if (startswith(argv[i], "--deserialize=") || streq(argv[i], "--deserialize"))
27082708
found_deserialize = true;
27092709

27102710
return found_deserialize; /* When we are deserializing, then we are reexecuting, hence avoid the extensive setup */

0 commit comments

Comments
 (0)