Skip to content

Commit

Permalink
Add const to pointer in blob_serialize() function.
Browse files Browse the repository at this point in the history
the data is read-only in this context.
  • Loading branch information
oniko committed Feb 6, 2025
1 parent 88b3da6 commit a965a88
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/luks2/luks2_reencrypt_digest.c
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit a965a88

Please sign in to comment.