[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Problem PPP Config Info

From: Nicolas Dioli
Subject: Re: [lwip-users] Problem PPP Config Info
Date: Thu, 01 Apr 2010 15:17:11 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv: Gecko/20100317 Lightning/1.0b1 Thunderbird/3.0.4

I am so confused: there is an initialization before the "if".
I think, i am very tired.
Sorry for the spam but i didn't see it during 3 hours.

Le 01/04/2010 14:46, Nicolas Dioli a écrit :
i don't understand a part of the code when ppp wants check the peer's requested CIs and send appropriate response.
In function "lcp_reqci()" of "lcp.c".
I don't understand the condition:

 u_char *p;                  /* Pointer to next char to parse */
    if (l < 2 ||        /* Not enough data for CI header or */
        p[1] < 2 ||     /*  CI length too small or */
        p[1] > l) {     /*  CI length too big? */

the pointer *p is not initialized previously. So, ppp send a config reject to the modem and never check the incoming config info.
Is this check important? Can i remove it? Is there an init to do ( memset, malloc)?

During my debug:
p: can't acess to memory

Ce message entrant est certifié sans virus connu. Analyse effectuée par AVG - www.avg.fr Version: 9.0.791 / Base de données virale: 271.1.1/2782 - Date: 03/31/10 20:32:00

Nicolas Dioli
Etudiant ingénieur
Tél : +33 (0)6 78 18 53 12

reply via email to

[Prev in Thread] Current Thread [Next in Thread]