lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] UDP pcb matching


From: Kieran Mansley
Subject: Re: [lwip-users] UDP pcb matching
Date: Fri, 29 Jul 2011 13:14:02 +0100

On Wed, 2011-07-06 at 10:40 +0200, Bertrand Roussel wrote:
> Hi, 
> 
> 
> I built a DHCP server which can answer different IP address depending
> on which interface it received the request from.
> In udp_input, when looking for a matching PCB, at some point there is
> a condition that match a PCB if:
> * PCB local port and UDP packet dest port are the same
> * UDP dest IP is broadcast
> 
> 
> This is fine for single interface devices, however if there is
> multiple interfaces listening on the same port, only the last
> registered PCB that match get the packet.
> 
> 
> I changed the second condition to:
> * (UDP dest IP is broadcast) and (PCB local ip and netif local ip are
> the same)

Apologies for the late reply, and thanks for sending in this fix.

Can you clarify what goes wrong in the existing code.  Is it that we are
delivering it to one PCB when you're hoping it will got to lots of PCBs?
Or is it that we're delivering it to the wrong PCB?

Getting a bug filed for this on savannah (if it hasn't already) would be
very helpful as otherwise they're likely to get forgotten.

Kieran




reply via email to

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