mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-11-06 02:27:15 +00:00
dns: Remove always true test in dns_alloc_random_port
The only way to exit the do-while loop is err != ERR_USE. Thus get rid of the always true test. Signed-off-by: Axel Lin <axel.lin@ingics.com>
This commit is contained in:
parent
764bf251cd
commit
6e863ecb50
@ -816,7 +816,7 @@ dns_alloc_random_port(void)
|
||||
}
|
||||
err = udp_bind(ret, IP_ADDR_ANY, port);
|
||||
} while (err == ERR_USE);
|
||||
if ((err != ERR_OK) && (err != ERR_USE)) {
|
||||
if (err != ERR_OK) {
|
||||
udp_remove(ret);
|
||||
return NULL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user