libzfs_sendrecv: Fix some comment style nits

* Capitalize and punctuate complete sentences.
* Add a blank line between functions.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ryan Moeller <freqlabs@FreeBSD.org>
Closes #12967
This commit is contained in:
Ryan Moeller 2021-09-13 14:51:02 +00:00 committed by Brian Behlendorf
parent 45932229d5
commit 2fafbfde9d
1 changed files with 5 additions and 4 deletions

View File

@ -1402,7 +1402,7 @@ zfs_send_resume_token_to_nvlist(libzfs_handle_t *hdl, const char *token)
return (NULL); return (NULL);
} }
/* convert hexadecimal representation to binary */ /* Convert hexadecimal representation to binary. */
token = strrchr(token, '-') + 1; token = strrchr(token, '-') + 1;
int len = strlen(token) / 2; int len = strlen(token) / 2;
unsigned char *compressed = zfs_alloc(hdl, len); unsigned char *compressed = zfs_alloc(hdl, len);
@ -1417,7 +1417,7 @@ zfs_send_resume_token_to_nvlist(libzfs_handle_t *hdl, const char *token)
} }
} }
/* verify checksum */ /* Verify checksum. */
zio_cksum_t cksum; zio_cksum_t cksum;
fletcher_4_native_varsize(compressed, len, &cksum); fletcher_4_native_varsize(compressed, len, &cksum);
if (cksum.zc_word[0] != checksum) { if (cksum.zc_word[0] != checksum) {
@ -1427,7 +1427,7 @@ zfs_send_resume_token_to_nvlist(libzfs_handle_t *hdl, const char *token)
return (NULL); return (NULL);
} }
/* uncompress */ /* Uncompress. */
void *packed = zfs_alloc(hdl, packed_len); void *packed = zfs_alloc(hdl, packed_len);
uLongf packed_len_long = packed_len; uLongf packed_len_long = packed_len;
if (uncompress(packed, &packed_len_long, compressed, len) != Z_OK || if (uncompress(packed, &packed_len_long, compressed, len) != Z_OK ||
@ -1439,7 +1439,7 @@ zfs_send_resume_token_to_nvlist(libzfs_handle_t *hdl, const char *token)
return (NULL); return (NULL);
} }
/* unpack nvlist */ /* Unpack nvlist. */
nvlist_t *nv; nvlist_t *nv;
int error = nvlist_unpack(packed, packed_len, &nv, KM_SLEEP); int error = nvlist_unpack(packed, packed_len, &nv, KM_SLEEP);
free(packed); free(packed);
@ -1451,6 +1451,7 @@ zfs_send_resume_token_to_nvlist(libzfs_handle_t *hdl, const char *token)
} }
return (nv); return (nv);
} }
static enum lzc_send_flags static enum lzc_send_flags
lzc_flags_from_sendflags(const sendflags_t *flags) lzc_flags_from_sendflags(const sendflags_t *flags)
{ {