summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorKarel Zak2017-12-12 11:54:08 +0100
committerKarel Zak2017-12-12 12:06:15 +0100
commit42dea85c5aee6059052716b85aa109a2f2c7e87c (patch)
tree8751a64266bcfaae60cd0b660cd6d0258f82454a /include
parentlib/sha1: fix indention (diff)
downloadkernel-qcow2-util-linux-42dea85c5aee6059052716b85aa109a2f2c7e87c.tar.gz
kernel-qcow2-util-linux-42dea85c5aee6059052716b85aa109a2f2c7e87c.tar.xz
kernel-qcow2-util-linux-42dea85c5aee6059052716b85aa109a2f2c7e87c.zip
lib/md5: use ul_/UL_ prefix
The symbols names are too generic. Addresses: https://github.com/karelzak/util-linux/issues/548 Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/md5.h25
1 files changed, 10 insertions, 15 deletions
diff --git a/include/md5.h b/include/md5.h
index d997e379d..d6991e1fd 100644
--- a/include/md5.h
+++ b/include/md5.h
@@ -1,29 +1,24 @@
-#ifndef MD5_H
-#define MD5_H
+#ifndef UTIL_LINUX_MD5_H
+#define UTIL_LINUX_MD5_H
-#ifdef HAVE_STDINT_H
#include <stdint.h>
-#else
-typedef unsigned int uint32_t;
-#endif
-#define MD5LENGTH 16
+#define UL_MD5LENGTH 16
-struct MD5Context {
+struct UL_MD5Context {
uint32_t buf[4];
uint32_t bits[2];
unsigned char in[64];
};
-void MD5Init(struct MD5Context *context);
-void MD5Update(struct MD5Context *context, unsigned char const *buf,
- unsigned len);
-void MD5Final(unsigned char digest[MD5LENGTH], struct MD5Context *context);
-void MD5Transform(uint32_t buf[4], uint32_t const in[16]);
+void ul_MD5Init(struct UL_MD5Context *context);
+void ul_MD5Update(struct UL_MD5Context *context, unsigned char const *buf, unsigned len);
+void ul_MD5Final(unsigned char digest[UL_MD5LENGTH], struct UL_MD5Context *context);
+void ul_MD5Transform(uint32_t buf[4], uint32_t const in[16]);
/*
* This is needed to make RSAREF happy on some MS-DOS compilers.
*/
-typedef struct MD5Context MD5_CTX;
+typedef struct UL_MD5Context UL_MD5_CTX;
-#endif /* !MD5_H */
+#endif /* !UTIL_LINUX_MD5_H */