mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 14:17:20 +00:00
ospfd: When failing to set socket options just note the failure
Instead of closing the socket, just note the failure and continue on. If we actually failed here so many other things would not be working at all, that actually closing the fd won't matter. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
147bb9ed61
commit
8ced966f39
@ -201,7 +201,6 @@ int ospf_sock_init(struct ospf *ospf)
|
||||
flog_err(EC_LIB_SOCKET,
|
||||
"Can't set IP_HDRINCL option for fd %d: %s",
|
||||
ospf_sock, safe_strerror(errno));
|
||||
close(ospf_sock);
|
||||
break;
|
||||
}
|
||||
#elif defined(IPTOS_PREC_INTERNETCONTROL)
|
||||
@ -213,7 +212,6 @@ int ospf_sock_init(struct ospf *ospf)
|
||||
flog_err(EC_LIB_SOCKET,
|
||||
"can't set sockopt IP_TOS %d to socket %d: %s",
|
||||
tos, ospf_sock, safe_strerror(errno));
|
||||
close(ospf_sock); /* Prevent sd leak. */
|
||||
break;
|
||||
}
|
||||
#else /* !IPTOS_PREC_INTERNETCONTROL */
|
||||
|
Loading…
Reference in New Issue
Block a user