]> git.ipfire.org Git - thirdparty/linux.git/commit
dm-stripe: small code cleanup
authorMikulas Patocka <mpatocka@redhat.com>
Tue, 3 Jun 2025 16:58:47 +0000 (18:58 +0200)
committerMikulas Patocka <mpatocka@redhat.com>
Tue, 3 Jun 2025 17:06:32 +0000 (19:06 +0200)
commit9f2f6316d753fe80c764e924cee475306f38ceb6
tree9869f519f2428ede7445f1c560d8707fbcb9ae75
parent66be40a14e496689e1f0add50118408e22c96169
dm-stripe: small code cleanup

This commit doesn't fix any bug, it is just code cleanup. Use the
function format_dev_t instead of sprintf, because format_dev_t does the
same thing.

Remove the useless memset call.

An unsigned integer can take at most 10 digits, so extend the array size
to 22. (note that because the range of minor and major numbers is limited,
the size 16 could not be exceeded, thus this function couldn't write
beyond string end)

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
drivers/md/dm-stripe.c