From 6eb9c5a5657d1fe77b55cc261450f3538d35a94d Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 4 May 2024 14:19:15 +0200 Subject: Adding upstream version 13.4. Signed-off-by: Daniel Baumann --- contrib/ltree/crc32.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 contrib/ltree/crc32.h (limited to 'contrib/ltree/crc32.h') diff --git a/contrib/ltree/crc32.h b/contrib/ltree/crc32.h new file mode 100644 index 0000000..9588122 --- /dev/null +++ b/contrib/ltree/crc32.h @@ -0,0 +1,12 @@ +#ifndef _CRC32_H +#define _CRC32_H + +/* contrib/ltree/crc32.h */ + +/* Returns crc32 of data block */ +extern unsigned int ltree_crc32_sz(const char *buf, int size); + +/* Returns crc32 of null-terminated string */ +#define crc32(buf) ltree_crc32_sz((buf),strlen(buf)) + +#endif -- cgit v1.2.3