From feb13fca97532b0a411a633fd601b93aa6f9275f Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 19 May 2020 09:23:00 +0200 Subject: [PATCH] repart: don't insist on coming up on partition label ourselves If the user specified a label, use that. Fixes: #15841 --- src/partition/repart.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/partition/repart.c b/src/partition/repart.c index 4c738920abc..46e82eaf90a 100644 --- a/src/partition/repart.c +++ b/src/partition/repart.c @@ -2233,7 +2233,6 @@ static int context_acquire_partition_uuids_and_labels(Context *context) { LIST_FOREACH(partitions, p, context->partitions) { assert(sd_id128_is_null(p->new_uuid)); - assert(!p->new_label); /* Never touch foreign partitions */ if (PARTITION_IS_FOREIGN(p)) { @@ -2256,6 +2255,9 @@ static int context_acquire_partition_uuids_and_labels(Context *context) { return r; } + if (p->new_label) /* Explicitly set by user? */ + continue; + if (!isempty(p->current_label)) { p->new_label = strdup(p->current_label); /* never change initialized labels */ if (!p->new_label)