UCHAR_MAX is defined in limits.h, I do not want to add any system include, replaced to 0xff

This commit is contained in:
Sylvain Rochet 2012-07-16 20:09:49 +02:00
parent a4f6146667
commit c65883a727
2 changed files with 2 additions and 2 deletions

View File

@ -738,7 +738,7 @@ pppoe_timeout(void *arg)
* We only enter slow retry mode if IFF_LINK1 (aka autodial)
* is not set.
*/
if (sc->sc_padi_retried < UCHAR_MAX) {
if (sc->sc_padi_retried < 0xff) {
sc->sc_padi_retried++;
}
if (!sc->pcb->settings.persist && sc->sc_padi_retried >= PPPOE_DISC_MAXPADI) {

View File

@ -567,7 +567,7 @@ static void pppol2tp_timeout(void *arg) {
switch (l2tp->phase) {
case PPPOL2TP_STATE_SCCRQ_SENT:
/* backoff wait */
if (l2tp->sccrq_retried < UCHAR_MAX) {
if (l2tp->sccrq_retried < 0xff) {
l2tp->sccrq_retried++;
}
if (!l2tp->ppp->settings.persist && l2tp->sccrq_retried >= PPPOL2TP_MAXSCCRQ) {