Commit 74da4989 authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

fix linking on Windows (iphlpapi missing)

parent a0331fec
...@@ -129,6 +129,7 @@ err: ...@@ -129,6 +129,7 @@ err:
#elif defined(_WIN32) #elif defined(_WIN32)
#include <winsock2.h> #include <winsock2.h>
#include <iphlpapi.h> #include <iphlpapi.h>
#pragma comment(lib, "iphlpapi.lib")
#define ETHER_ADDR_LEN 6 #define ETHER_ADDR_LEN 6
...@@ -142,7 +143,7 @@ my_bool my_gethwaddr(uchar *to) ...@@ -142,7 +143,7 @@ my_bool my_gethwaddr(uchar *to)
if (GetAdaptersInfo(info, &info_len) != ERROR_BUFFER_OVERFLOW) if (GetAdaptersInfo(info, &info_len) != ERROR_BUFFER_OVERFLOW)
goto err; goto err;
info= alloca(info_len); info= (IP_ADAPTER_INFO *)alloca(info_len);
if (GetAdaptersInfo(info, &info_len) != NO_ERROR) if (GetAdaptersInfo(info, &info_len) != NO_ERROR)
goto err; goto err;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment