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