summaryrefslogtreecommitdiff
path: root/lib/libcrypt
diff options
context:
space:
mode:
authorMark Murray <markm@FreeBSD.org>2002-03-07 10:41:11 +0000
committerMark Murray <markm@FreeBSD.org>2002-03-07 10:41:11 +0000
commitbbf177c2a974ab490fad87961bb286b3ce660325 (patch)
tree591f1815dea7709dd66950949081df7245f563a2 /lib/libcrypt
parent9164438ed2fcffd6fb86b7f31fa0f7d44c037da5 (diff)
Notes
Diffstat (limited to 'lib/libcrypt')
-rw-r--r--lib/libcrypt/crypt-md5.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libcrypt/crypt-md5.c b/lib/libcrypt/crypt-md5.c
index e6fbe722d1cd..584563a478a9 100644
--- a/lib/libcrypt/crypt-md5.c
+++ b/lib/libcrypt/crypt-md5.c
@@ -26,8 +26,8 @@ crypt_md5(const char *pw, const char *salt)
{
MD5_CTX ctx,ctx1;
unsigned long l;
- int sl;
- u_int pl, i;
+ int sl, pl;
+ u_int i;
u_char final[MD5_SIZE];
static const char *sp, *ep;
static char passwd[120], *p;
@@ -69,9 +69,9 @@ crypt_md5(const char *pw, const char *salt)
MD5Update(&ctx1, (const u_char *)sp, (u_int)sl);
MD5Update(&ctx1, (const u_char *)pw, strlen(pw));
MD5Final(final, &ctx1);
- for(pl = strlen(pw); pl > 0; pl -= MD5_SIZE)
+ for(pl = (int)strlen(pw); pl > 0; pl -= MD5_SIZE)
MD5Update(&ctx, (const u_char *)final,
- pl > MD5_SIZE ? MD5_SIZE : pl);
+ (u_int)(pl > MD5_SIZE ? MD5_SIZE : pl));
/* Don't leave anything around in vm they could use. */
memset(final, 0, sizeof(final));