$NetBSD: patch-am,v 1.1.1.1 2005/01/02 02:51:42 cube Exp $ --- pppd/chap_ms.c.orig 2004-11-12 10:57:43.000000000 +0100 +++ pppd/chap_ms.c @@ -89,7 +89,11 @@ #include "pppd.h" #include "chap-new.h" #include "chap_ms.h" +#ifdef __NetBSD__ +#include +#else #include "md4.h" +#endif #include "sha1.h" #include "pppcrypt.h" #include "magic.h" @@ -574,7 +578,7 @@ ChapMS_LANMan(u_char *rchallenge, char * /* LANMan password is case insensitive */ BZERO(UcasePassword, sizeof(UcasePassword)); for (i = 0; i < secret_len; i++) - UcasePassword[i] = (u_char)toupper(secret[i]); + UcasePassword[i] = (u_char)toupper((unsigned char)secret[i]); (void) DesSetkey(UcasePassword + 0); DesEncrypt( StdText, PasswordHash + 0 ); (void) DesSetkey(UcasePassword + 7);