[Top][All Lists]

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

Re: [lwip-users] Callback when get any IP or ICMP packet?

From: narke
Subject: Re: [lwip-users] Callback when get any IP or ICMP packet?
Date: Mon, 10 Oct 2011 09:11:20 +0800

On 9 October 2011 00:40, Simon Goldschmidt <address@hidden> wrote:
> narke <address@hidden> wrote:
>> For the technical you mentioned, would you please show me a code
>> illustration?  I just need to 'listen' on any IP packet coming to my
>> interface but without changing it.  Hacking ip_input() might be a
>> solution (as Kieran probably pointed out), but I am looking for a
>> better way.
> As i said, a good example for using a raw pcb is in the ping app. Have you 
> had a look at it? In the receive callback, just always return 0, then no 
> packet will get changed.
> Simon


Many thanks!  I check the ping.c and get understand the raw_bind() and
raw_recv() APIs.  They are nice!

Life is the only flaw in an otherwise perfect nonexistence
    -- Schopenhauer

public key at http://subkeys.pgp.net:11371 (address@hidden)

reply via email to

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