diff --git a/lib/luks1/af.c b/lib/luks1/af.c index 0cb0dfea..f0c1e168 100644 --- a/lib/luks1/af.c +++ b/lib/luks1/af.c @@ -50,10 +50,10 @@ static int hash_buf(const char *src, char *dst, uint32_t iv, if ((r = crypt_hash_write(hd, iv_char, sizeof(uint32_t)))) goto out; - + if ((r = crypt_hash_write(hd, src, len))) goto out; - + r = crypt_hash_final(hd, dst, len); out: crypt_hash_destroy(hd); diff --git a/lib/luks1/af.h b/lib/luks1/af.h index 78f978c7..c6cc8eb3 100644 --- a/lib/luks1/af.h +++ b/lib/luks1/af.h @@ -7,9 +7,9 @@ */ /* - * AF_split operates on src and produces information splitted data in + * AF_split operates on src and produces information split data in * dst. src is assumed to be of the length blocksize. The data stripe - * dst points to must be captable of storing blocksize*blocknumbers. + * dst points to must be capable of storing blocksize*blocknumbers. * blocknumbers is the data multiplication factor. * * AF_merge does just the opposite: reproduces the information stored in diff --git a/lib/luks1/keymanage.c b/lib/luks1/keymanage.c index af957d32..31fea77e 100644 --- a/lib/luks1/keymanage.c +++ b/lib/luks1/keymanage.c @@ -572,7 +572,7 @@ int LUKS_set_key(const char *device, unsigned int keyIndex, goto out; /* - * AF splitting, the masterkey stored in vk->key is splitted to AfMK + * AF splitting, the masterkey stored in vk->key is split to AfKey */ AFEKSize = hdr->keyblock[keyIndex].stripes*vk->keylength; AfKey = crypt_safe_alloc(AFEKSize);