From a954b427e9c53e4192eae3e72f64e05721e17a99 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Thu, 14 Mar 2024 08:53:55 +0100 Subject: [PATCH] src/partition: remove unnecessary uses of "make sure" --- src/partition/repart.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/partition/repart.c b/src/partition/repart.c index adf1f0e696..ddb7fcb046 100644 --- a/src/partition/repart.c +++ b/src/partition/repart.c @@ -3329,8 +3329,8 @@ static int context_dump(Context *context, bool late) { if (r < 0) return r; - /* Make sure we only write the partition bar once, even if we're writing the partition table twice to - * communicate roothashes. */ + /* Only write the partition bar once, even if we're writing the partition table twice to communicate + * roothashes. */ if (FLAGS_SET(arg_json_format_flags, JSON_FORMAT_OFF) && !late) { putc('\n', stdout); @@ -4239,7 +4239,7 @@ static int partition_format_verity_hash( if (PARTITION_EXISTS(p)) /* Never format existing partitions */ return 0; - /* Minimized partitions will use the copy blocks logic so let's make sure to skip those here. */ + /* Minimized partitions will use the copy blocks logic so skip those here. */ if (p->copy_blocks_fd >= 0) return 0; @@ -4986,7 +4986,7 @@ static int context_mkfs(Context *context) { if (!p->format) continue; - /* Minimized partitions will use the copy blocks logic so let's make sure to skip those here. */ + /* Minimized partitions will use the copy blocks logic so skip those here. */ if (p->copy_blocks_fd >= 0) continue; @@ -4997,7 +4997,7 @@ static int context_mkfs(Context *context) { assert(p->new_size != UINT64_MAX); assert(p->new_size >= (p->encrypt != ENCRYPT_OFF ? LUKS2_METADATA_KEEP_FREE : 0)); - /* If we're doing encryption, we make sure we keep free space at the end which is required + /* If we're doing encryption, keep free space at the end which is required * for cryptsetup's offline encryption. */ r = partition_target_prepare(context, p, p->new_size - (p->encrypt != ENCRYPT_OFF ? LUKS2_METADATA_KEEP_FREE : 0), @@ -5046,8 +5046,8 @@ static int context_mkfs(Context *context) { return r; /* The mkfs binary we invoked might have removed our temporary file when we're not operating - * on a loop device, so let's make sure we open the file again to make sure our file - * descriptor points to any potential new file. */ + * on a loop device, so open the file again to make sure our file descriptor points to actual + * new file. */ if (t->fd >= 0 && t->path && !t->loop) { safe_close(t->fd); -- 2.25.1