From 3cc99313fc75043c07720bf64e5ac76496057864 Mon Sep 17 00:00:00 2001 From: hackbard Date: Thu, 17 Oct 2002 15:57:16 +0000 Subject: [PATCH] added SO_BROADCAST support --- datagram.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/datagram.c b/datagram.c index 5f47a45..83c4bc8 100644 --- a/datagram.c +++ b/datagram.c @@ -41,6 +41,8 @@ int main(int argc, char *argv[]) { printf("can't open socket.\n"); exit(1); } + + // setsockopt(send_fd,SOL_SOCKET,SO_BROADCAST, memset(&local_addr,0,sizeof(local_addr)); local_addr.sin_family=AF_INET; -- 2.39.2