[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Problem with NULL pcb->callback_arg
From: |
Baptiste Chaboud-crousaz |
Subject: |
Re: [lwip-users] Problem with NULL pcb->callback_arg |
Date: |
Thu, 6 Aug 2009 15:41:47 +0200 |
User-agent: |
Internet Messaging Program (IMP) H3 (4.1.6) |
Simon,
The code I sent the last time checked that the arg is not NULL.
But this is a fix: in the version provided by contrib/ no check is done to
ensure that arg is not NULL. In my case, if arg is NULL the next instructions:
hcs = arg and hcs->retries++ consists in access a NULL pointer that raises
an error (named hard fault exception - you access 0x0!!!!!!).
By checking
that arg is not NULL the hard fault exception is avoided but it means that the
HTTP server does not work as expected because http_sent is called to send data
but nothing is done!
Baptiste
Quoting Simon Goldschmidt <address@hidden>:
>
> Baptiste Chaboud-crousaz wrote:
>> Can you explain me what is the purpose of this function?
>>
>
> The poll function is used for timeout handling. For example, the http
> server closes connections that are idle for too long (poll is called
> twice without data sent or received in between).
>
>
> Regarding your initial problem, I know it's not correct that arg is
> NULL in http_sent (and I'm afraid I don't know why - doesn't happen
> here with the httpd in contrib), but why do you get a "hardfault
> exception" (whatever that is)? The code you sent last time seemed
to
> check for a NULL-pointer correctly...
>
> Simon
>
>
> _______________________________________________
> lwip-users mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/lwip-users
- [lwip-users] Problem with NULL pcb->callback_arg, Baptiste Chaboud-crousaz, 2009/08/04
- Re: [lwip-users] Problem with NULL pcb->callback_arg, address@hidden, 2009/08/04
- Re: [lwip-users] Problem with NULL pcb->callback_arg, Baptiste Chaboud-crousaz, 2009/08/04
- Re: [lwip-users] Problem with NULL pcb->callback_arg, Baptiste Chaboud-crousaz, 2009/08/06
- RE: [lwip-users] Problem with NULL pcb->callback_arg, Bill Auerbach, 2009/08/06
- RE: [lwip-users] Problem with NULL pcb->callback_arg, Baptiste Chaboud-crousaz, 2009/08/06
- Re: [lwip-users] Problem with NULL pcb->callback_arg, Simon Goldschmidt, 2009/08/06
- Re: [lwip-users] Problem with NULL pcb->callback_arg,
Baptiste Chaboud-crousaz <=
- Re: [lwip-users] Problem with NULL pcb->callback_arg, Chris_S, 2009/08/06
- [lwip-users] [TCP Previous segment lost] / [TCP Out-Of-Order] (HTTPd-RAW), Chris_S, 2009/08/10
- Re: [lwip-users] [TCP Previous segment lost] / [TCP Out-Of-Order] (HTTPd-RAW), Kieran Mansley, 2009/08/10
- Re: [lwip-users] [TCP Previous segment lost] / [TCP Out-Of-Order] (HTTPd-RAW), Chris_S, 2009/08/10