From 4f78cdb9d9ac293acd243e9f92c8eeace2158a23 Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 8 Jun 2017 02:52:20 +0200 Subject: Disable broadcast loopbackl --- artnet.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'artnet.c') diff --git a/artnet.c b/artnet.c index 3c76f21..fe9efd9 100644 --- a/artnet.c +++ b/artnet.c @@ -50,6 +50,11 @@ static int artnet_listener(char* host, char* port){ fprintf(stderr, "Failed to set SO_BROADCAST on socket\n"); } + yes = 0; + if(setsockopt(fd, IPPROTO_IP, IP_MULTICAST_LOOP, (void*)&yes, sizeof(yes)) < 0){ + fprintf(stderr, "Failed to unset IP_MULTICAST_LOOP option: %s\n", strerror(errno)); + } + status = bind(fd, addr_it->ai_addr, addr_it->ai_addrlen); if(status < 0){ close(fd); -- cgit v1.2.3