summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/fixer.h8
-rw-r--r--src/md5.c2
-rw-r--r--src/md5.h10
3 files changed, 18 insertions, 2 deletions
diff --git a/src/fixer.h b/src/fixer.h
index 173b82a..3913c05 100644
--- a/src/fixer.h
+++ b/src/fixer.h
@@ -1,6 +1,10 @@
#ifndef __FIXER_H__
#define __FIXER_H__
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -112,4 +116,8 @@ int GetFileAttributesA(const char *file);
int SetFilePointer(HANDLE file, int x, int y, int z);
int SetEndOfFile(HANDLE file);
+#ifdef __cplusplus
+};
+#endif
+
#endif
diff --git a/src/md5.c b/src/md5.c
index aedacc7..4117a55 100644
--- a/src/md5.c
+++ b/src/md5.c
@@ -46,7 +46,7 @@ byteSwap(UWORD32 *buf, unsigned words)
#endif
/* md5_buffer frontend added for AvP */
-void md5_buffer(const char *buffer, unsigned len, char *digest)
+void md5_buffer(char const *buffer, unsigned int len, char *digest)
{
struct MD5Context md5c;
diff --git a/src/md5.h b/src/md5.h
index b3c4f80..86e8ac1 100644
--- a/src/md5.h
+++ b/src/md5.h
@@ -25,6 +25,10 @@
#ifndef MD5_H
#define MD5_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
typedef unsigned int UWORD32;
#define md5byte unsigned char
@@ -41,6 +45,10 @@ void MD5Final(unsigned char digest[16], struct MD5Context *context);
void MD5Transform(UWORD32 buf[4], UWORD32 const in[16]);
/* md5_buffer frontend added for AvP */
-void md5_buffer(const char *buffer, unsigned len, char *digest);
+void md5_buffer(char const *buffer, unsigned int len, char *digest);
+
+#ifdef __cplusplus
+};
+#endif
#endif /* !MD5_H */