Add const to pointer in blob_serialize() function.

the data is read-only in this context.
This commit is contained in:
Ondrej Kozina
2025-01-31 15:59:22 +01:00
parent 88b3da6042
commit a965a88992

View File

@@ -240,7 +240,7 @@ static size_t reenc_keyslot_serialize(struct luks2_hdr *hdr, uint8_t *buffer)
return srs(j, buffer);
}
static size_t blob_serialize(void *blob, size_t length, uint8_t *buffer)
static size_t blob_serialize(const void *blob, size_t length, uint8_t *buffer)
{
if (buffer)
crypt_safe_memcpy(buffer, blob, length);