lsalzman / enet

ENet reliable UDP networking library
MIT License
2.72k stars 670 forks source link

VS2013 Compilation Error #36

Open kklouzal opened 10 years ago

kklouzal commented 10 years ago

Compiling on Visual Studio 2013 outputs the following compiler errors:

src\enet\win32.c(67): error C4996: 'gethostbyname': Use getaddrinfo() or GetAddrInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings

src\enet\win32.c(71): error C4996: 'inet_addr': Use inet_pton() or InetPton() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings

src\enet\win32.c(86): error C4996: 'inet_ntoa': Use inet_ntop() or InetNtop() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings

src\enet\win32.c(107): error C4996: 'gethostbyaddr': Use getnameinfo() or GetNameInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings

I of course can define that preprocessor macro, but I wanted to make sure you were aware depreciated function calls were being used.

creikey commented 1 year ago

Still true in 2022

Croydon commented 5 months ago

How are you compiling enet? With CMake and VS this should be warnings not errors