rchallenge = inp;
INCPTR(rchallenge_len, inp);
- if (len >= sizeof(rhostname)) {
+ if (len >= (int)sizeof(rhostname)) {
len = sizeof(rhostname) - 1;
}
BCOPY(inp, rhostname, len);
UNTIMEOUT(ChapChallengeTimeout, cstate);
- if (len >= sizeof(rhostname)) {
+ if (len >= (int)sizeof(rhostname)) {
len = sizeof(rhostname) - 1;
}
BCOPY(inp, rhostname, len);
ipcp_options ipcp_hisoptions[NUM_PPP]; /* Options that we ack'd */
/* local vars */
-static int cis_received[NUM_PPP]; /* # Conf-Reqs received */
static int default_route_set[NUM_PPP]; /* Have set up a default route */
+static int cis_received[NUM_PPP]; /* # Conf-Reqs received */
+
/*
* Callbacks for fsm code. (CI = Configuration Information)
goto bad;
}
return (1);
-
+
bad:
IPCPDEBUG((LOG_INFO, "ipcp_ackci: received bad Ack!\n"));
return (0);
fsm *f = &lcp_fsm[unit];
lcp_options *wo = &lcp_wantoptions[unit];
lcp_options *ao = &lcp_allowoptions[unit];
-
+
f->unit = unit;
f->protocol = PPP_LCP;
f->callbacks = &lcp_callbacks;
struct protent *protp;
u_short prot;
- if (len < sizeof (u_short)) {
+ if (len < (int)sizeof (u_short)) {
LCPDEBUG((LOG_INFO, "lcp_rprotrej: Rcvd short Protocol-Reject packet!\n"));
return;
}
u->us_unit, u->us_timeouttime, u->us_clientstate));
if (u->us_clientstate != UPAPCS_AUTHREQ) {
+ UPAPDEBUG((LOG_INFO, "upap_timeout: not in AUTHREQ state!\n"));
return;
}
* If packet too short, drop it.
*/
inp = inpacket;
- if (l < UPAP_HEADERLEN) {
+ if (l < (int)UPAP_HEADERLEN) {
UPAPDEBUG((LOG_INFO, "pap_input: rcvd short header.\n"));
return;
}
GETCHAR(code, inp);
GETCHAR(id, inp);
GETSHORT(len, inp);
- if (len < UPAP_HEADERLEN) {
+ if (len < (int)UPAP_HEADERLEN) {
UPAPDEBUG((LOG_INFO, "pap_input: rcvd illegal length.\n"));
return;
}
break;
default: /* XXX Need code reject */
+ UPAPDEBUG((LOG_INFO, "pap_input: UNHANDLED default: code: %d, id: %d, len: %d.\n", code, id, len));
break;
}
}
/*
* Parse user/passwd.
*/
- if (len < sizeof (u_char)) {
+ if (len < (int)sizeof (u_char)) {
UPAPDEBUG((LOG_INFO, "pap_rauth: rcvd short packet.\n"));
return;
}
UPAPDEBUG((LOG_INFO, "pap_rauthack: Rcvd id %d s=%d\n", id, u->us_clientstate));
if (u->us_clientstate != UPAPCS_AUTHREQ) { /* XXX */
+ UPAPDEBUG((LOG_INFO, "pap_rauthack: us_clientstate != UPAPCS_AUTHREQ\n"));
return;
}
/*
* Parse message.
*/
- if (len < sizeof (u_char)) {
+ if (len < (int)sizeof (u_char)) {
UPAPDEBUG((LOG_INFO, "pap_rauthack: ignoring missing msg-length.\n"));
} else {
GETCHAR(msglen, inp);
* Parse message.
*/
if (len < sizeof (u_char)) {
- UPAPDEBUG((LOG_INFO, "pap_rauthnak: rcvd short packet.\n"));
+ UPAPDEBUG((LOG_INFO, "pap_rauthnak: ignoring missing msg-length.\n"));
} else {
GETCHAR(msglen, inp);
if(msglen > 0) {