mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-08 09:30:30 +00:00
lib: compile even without IPV6_TCLASS
This commit is contained in:
parent
d1e2faa40e
commit
d14a71d720
@ -183,12 +183,14 @@ getsockopt_ipv6_ifindex (struct msghdr *msgh)
|
|||||||
int
|
int
|
||||||
setsockopt_ipv6_tclass(int sock, int tclass)
|
setsockopt_ipv6_tclass(int sock, int tclass)
|
||||||
{
|
{
|
||||||
int ret;
|
int ret = 0;
|
||||||
|
|
||||||
|
#ifdef IPV6_TCLASS /* RFC3542 */
|
||||||
ret = setsockopt (sock, IPPROTO_IPV6, IPV6_TCLASS, &tclass, sizeof (tclass));
|
ret = setsockopt (sock, IPPROTO_IPV6, IPV6_TCLASS, &tclass, sizeof (tclass));
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
zlog_warn ("Can't set IPV6_TCLASS option for fd %d to %#x: %s",
|
zlog_warn ("Can't set IPV6_TCLASS option for fd %d to %#x: %s",
|
||||||
sock, tclass, safe_strerror(errno));
|
sock, tclass, safe_strerror(errno));
|
||||||
|
#endif
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
#endif /* HAVE_IPV6 */
|
#endif /* HAVE_IPV6 */
|
||||||
|
Loading…
Reference in New Issue
Block a user