partitions/ibm: Remove unnecessary memset

The data holding the volume label information is zeroed in case no valid
volume label was found. Since the label information isn't used in that
case, zeroing the data doesn't provide any value whatsoever.

Remove the unnecessary memset() call accordingly.

Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://lore.kernel.org/r/20230915131001.697070-2-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
Jan Höppner 2023-09-15 15:09:59 +02:00 committed by Jens Axboe
parent 5e9b7cfc20
commit d323c1a947

View File

@ -124,8 +124,6 @@ static int find_label(struct parsed_partitions *state,
break;
}
}
if (!found)
memset(label, 0, sizeof(*label));
return found;
}