fpc 3.0.0 support - fpc 3 renames fields in TInetSockAddr so we define it ourselves...
[lcore.git] / dnswin.pas
index 17a8a97a02830ad4e4468465bfb14316aeb60092..ac1a6877a5b7cda60824d03738ae706ef126bed5 100644 (file)
@@ -110,7 +110,7 @@ begin
 \r
       getmem(output,sizeof(taddrinfo));\r
       if assigned(prev) then prev.ai_next := output;\r
-      getmem(output.ai_addr,sizeof(tinetsockaddr));\r
+      getmem(output.ai_addr,sizeof(tlinetsockaddr4));\r
       if servname <> nil then output.ai_addr.InAddr.port := htons(strtoint(servname)) else output.ai_addr.InAddr.port := 0;\r
       output.ai_addr.InAddr.addr := longint(addrlist^^);\r
       inc(integer(addrlist),4);\r
@@ -118,7 +118,7 @@ begin
       output.ai_family := af_inet;\r
       output.ai_socktype := 0;\r
       output.ai_protocol := 0;\r
-      output.ai_addrlen := sizeof(tinetsockaddr);\r
+      output.ai_addrlen := sizeof(tlinetsockaddr4);\r
       output.ai_canonname := nil;\r
       output.ai_next := nil;\r
       prev := output;\r