mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-11-08 12:18:42 +00:00
Use (SOCK_DGRAM,IPPROTO_IP) socket instead of (SOCK_STREAM,IPPROTO_TCP).
This is exactly what Linux ifconfig does and seems to be the preferred way.
This commit is contained in:
parent
4cf45766ba
commit
567e6c6220
@ -170,7 +170,7 @@ scan_if(timer *t)
|
||||
void
|
||||
scan_if_init(void)
|
||||
{
|
||||
if_scan_sock = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP);
|
||||
if_scan_sock = socket(PF_INET, SOCK_DGRAM, IPPROTO_IP);
|
||||
DBG("Using socket %d for interface and route scanning\n", if_scan_sock);
|
||||
if (if_scan_sock < 0)
|
||||
die("Cannot create scanning socket: %m");
|
||||
|
Loading…
Reference in New Issue
Block a user