[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [patch #7773] "netconn_bind" broken for UDP connections in
From: |
Simon Goldschmidt |
Subject: |
[lwip-devel] [patch #7773] "netconn_bind" broken for UDP connections in LwIP 1.4.0 |
Date: |
Thu, 03 May 2012 07:35:20 +0000 |
User-agent: |
Mozilla/5.0 (Windows NT 5.1; rv:12.0) Gecko/20100101 Firefox/12.0 |
Update of patch #7773 (project lwip):
Status: Works For Me => Invalid
Open/Closed: Open => Closed
_______________________________________________________
Follow-up Comment #5:
Well, if netconn_bind() returns and error, ou simply get the behaviour you
would have had without calling it, i.e. you just get the next free port as
local port.
netconn_bind() returning "Address in use" means you have another udp pcb using
the same local IP address and port. This is not allowed, but before 1.4.0, we
didn't check for duplicate ports (that code was marked with "todo").
However, you can reuse local ports if you want, but you have to set SO_REUSE
to 1 in lwipopts.h and set the SOF_REUSEADDR flag on *all* udp pcbs using the
same port:
for 1.4.1:
ip_set_option(your_pcb, SOF_REUSEADDR);
or for 1.4.0:
your_pcb->so_options |= SOF_REUSEADDR;
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/patch/?7773>
_______________________________________________
Nachricht gesendet von/durch Savannah
http://savannah.nongnu.org/