X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=pppd%2Fupap.c;h=5cf9c683098894f2acca9567472835bfa5986b83;hb=739142cddb7369c7611eeed081a80d52b7b992c9;hp=6bf8dece21411fc3cc94c89a99683485b9499f45;hpb=4faf67061e6954ee068278dc0b8155207771c316;p=ppp.git diff --git a/pppd/upap.c b/pppd/upap.c index 6bf8dec..5cf9c68 100644 --- a/pppd/upap.c +++ b/pppd/upap.c @@ -17,7 +17,7 @@ * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#define RCSID "$Id: upap.c,v 1.20 1999/08/24 05:29:26 paulus Exp $" +#define RCSID "$Id: upap.c,v 1.21 1999/09/11 12:09:00 paulus Exp $" /* * TODO: @@ -395,8 +395,11 @@ upap_rauthreq(u, inp, id, len) * Check the username and password given. */ retcode = check_passwd(u->us_unit, ruser, ruserlen, rpasswd, - rpasswdlen, &msg, &msglen); + rpasswdlen, &msg); BZERO(rpasswd, rpasswdlen); + msglen = strlen(msg); + if (msglen > 255) + msglen = 255; upap_sresp(u, retcode, id, msg, msglen);