]> git.sesse.net Git - vlc/commitdiff
Win32: don't call setsockopt if compiling for Windows 8.0
authorJean-Baptiste Kempf <jb@videolan.org>
Fri, 20 Mar 2015 14:47:04 +0000 (15:47 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Fri, 20 Mar 2015 14:47:04 +0000 (15:47 +0100)
src/network/udp.c

index d33b13a11f0c5d2498e68b60a114f3a15a2fabb6..72bd34620b4d34aec8090961fdb58d6ee463aee5 100644 (file)
@@ -104,6 +104,7 @@ static int net_SetupDgramSocket (vlc_object_t *p_obj, int fd,
      * SetSocketMediaStreamingMode is present in win 8 and later, so we set
      * receive buffer if that isn't present
      */
+#if _WIN32_WINNT < 0x602
     HINSTANCE h_Network = LoadLibraryW(L"Windows.Networking.dll");
     if( (h_Network == NULL) ||
         (GetProcAddress( h_Network, "SetSocketMediaStreamingMode" ) == NULL ) )
@@ -113,6 +114,7 @@ static int net_SetupDgramSocket (vlc_object_t *p_obj, int fd,
     }
     if( h_Network )
         FreeLibrary( h_Network );
+#endif
 
     if (net_SockAddrIsMulticast (ptr->ai_addr, ptr->ai_addrlen)
      && (sizeof (struct sockaddr_storage) >= ptr->ai_addrlen))