]> git.proxmox.com Git - mirror_edk2.git/blobdiff - AppPkg/Applications/Sockets/GetHostByDns/GetHostByDns.c
Merged socket development branch:
[mirror_edk2.git] / AppPkg / Applications / Sockets / GetHostByDns / GetHostByDns.c
index 47453aced2ef40e97decbacc2daaacd8c26e225b..a9aa183e40c540d53a1c441b82e9979b93cf106b 100644 (file)
@@ -23,9 +23,9 @@
 \r
 #include <sys/socket.h>\r
 \r
 \r
 #include <sys/socket.h>\r
 \r
-struct hostent * _gethostbydnsname(const char *, int);\r
+struct hostent * _gethostbydnsname (const char *, int);\r
 \r
 \r
-char mBuffer [65536];\r
+char mBuffer[65536];\r
 \r
 \r
 /**\r
 \r
 \r
 /**\r
@@ -64,7 +64,7 @@ main (
     //\r
     pHost = _gethostbydnsname ( Argv[1], AF_INET );\r
     if ( NULL == pHost ) {\r
     //\r
     pHost = _gethostbydnsname ( Argv[1], AF_INET );\r
     if ( NULL == pHost ) {\r
-      Print ( L"ERROR - host not found, errno: %d\r\n", errno );\r
+      Print ( L"ERROR - host not found, h_errno: %d\r\n", h_errno );\r
     }\r
     else {\r
       pIpAddress = (UINT8 *)pHost->h_addr;\r
     }\r
     else {\r
       pIpAddress = (UINT8 *)pHost->h_addr;\r