summaryrefslogtreecommitdiff
path: root/libcrypt/md5.c
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-08-24 02:43:08 +0000
committerMike Frysinger <vapier@gentoo.org>2006-08-24 02:43:08 +0000
commit8d9ff89b645bfe6f5143eb97d650a34aeee23d28 (patch)
tree17edca4779de6591603dc0a6d990056e977acea6 /libcrypt/md5.c
parent8f2da7e653fab73b1b628731eca01dd904d81a10 (diff)
fix by Bernhard Fischer to move local prototypes to a header to keep things sane
Diffstat (limited to 'libcrypt/md5.c')
-rw-r--r--libcrypt/md5.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/libcrypt/md5.c b/libcrypt/md5.c
index 412c8bfb5..841ed8342 100644
--- a/libcrypt/md5.c
+++ b/libcrypt/md5.c
@@ -79,7 +79,8 @@
#include <stdio.h>
#include <crypt.h>
#include <sys/cdefs.h>
-
+#include "libcrypt.h"
+
/* MD5 context. */
struct MD5Context {
u_int32_t state[4]; /* state (ABCD) */
@@ -100,14 +101,6 @@ static const unsigned char __md5_itoa64[] = /* 0 ... 63 => ascii - 64 */
"./0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
-/* shut up gcc-4.x signed warnings */
-#define strcpy(dst,src) strcpy((char*)dst,(char*)src)
-#define strlen(s) strlen((char*)s)
-#define strncat(dst,src,n) strncat((char*)dst,(char*)src,n)
-#define strncmp(s1,s2,n) strncmp((char*)s1,(char*)s2,n)
-
-
-
#ifdef i386
#define __md5_Encode memcpy
#define __md5_Decode memcpy
@@ -538,8 +531,7 @@ static void __md5_to64( char *s, unsigned long v, int n)
* Use MD5 for what it is best at...
*/
-char * __md5_crypt( const unsigned char *pw, const unsigned char *salt) attribute_hidden;
-char * __md5_crypt( const unsigned char *pw, const unsigned char *salt)
+char *__md5_crypt(const unsigned char *pw, const unsigned char *salt)
{
/* Static stuff */
static const unsigned char *sp, *ep;