Skip to content

Commit ed474d3

Browse files
yuwatabluca
authored andcommitted
repart: initialize seed earlier
As the seed is used by context_load_partition_table() -> derive_uuid(). Fixes #34257. (cherry picked from commit b8a8000) (cherry picked from commit f85a4fb) (cherry picked from commit 175dafa)
1 parent b431088 commit ed474d3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/partition/repart.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6957,6 +6957,10 @@ static int run(int argc, char *argv[]) {
69576957
if (!context)
69586958
return log_oom();
69596959

6960+
r = context_read_seed(context, arg_root);
6961+
if (r < 0)
6962+
return r;
6963+
69606964
strv_uniq(arg_definitions);
69616965

69626966
r = context_read_definitions(context);
@@ -7012,10 +7016,6 @@ static int run(int argc, char *argv[]) {
70127016
return r;
70137017
}
70147018

7015-
r = context_read_seed(context, arg_root);
7016-
if (r < 0)
7017-
return r;
7018-
70197019
/* Make sure each partition has a unique UUID and unique label */
70207020
r = context_acquire_partition_uuids_and_labels(context);
70217021
if (r < 0)

0 commit comments

Comments
 (0)