summaryrefslogtreecommitdiff
path: root/lib/crc32.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/crc32.c')
-rw-r--r--lib/crc32.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/crc32.c b/lib/crc32.c
index 27335a3ed9..76205da4f3 100644
--- a/lib/crc32.c
+++ b/lib/crc32.c
@@ -249,3 +249,12 @@ uint32_t ZEXPORT crc32_wd (uint32_t crc,
return crc;
}
+
+void crc32_wd_buf(const unsigned char *input, unsigned int ilen,
+ unsigned char *output, unsigned int chunk_sz)
+{
+ uint32_t crc;
+
+ crc = crc32_wd(0, input, ilen, chunk_sz);
+ memcpy(output, &crc, sizeof(crc));
+}