ãã«ããã£ã¹ãéä¿¡ãµã³ãã« ã¾ãã¯ããã«ããã£ã¹ããéä¿¡ãããµã³ãã«ã以ä¸ã«ç¤ºãã¾ãã ãã®ãµã³ãã«ã§ã¯winsock2.hã ãã§ãªãws2tcpip.hã¨ãããã¡ã¤ã«ãincludeãã¦ããã®ã§æ³¨æãã¦ãã ããã ws2tcpip.hã§IP_MULTICAST_IFãstruct ip_mreqãªã©ã宣è¨ããã¦ãã¾ãã #include <stdio.h> #include <winsock2.h> #include <ws2tcpip.h> int main() { WSAData wsaData; SOCKET sock; struct sockaddr_in addr; DWORD ipaddr; WSAStartup(MAKEWORD(2,0), &wsaData); sock = socket(AF_INET, SOCK_DGRAM, 0); addr.sin_family =
{{#tags}}- {{label}}
{{/tags}}