]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/sckaddr.cpp
Fix assert when editing an item in multi-selection wxTreeCtrl.
[wxWidgets.git] / src / common / sckaddr.cpp
index 79cc6c4cac8c02565b6e5a1d3cd1a1ae88658658..0e1a95c96e53d92007d14644063d63ad1fc66cae 100644 (file)
@@ -273,8 +273,9 @@ hostent *wxGethostbyname_r(const char *hostname,
 #elif defined(HAVE_FUNC_GETHOSTBYNAME_R_5)
     he = gethostbyname_r(hostname, h, buffer, size, err);
 #elif defined(HAVE_FUNC_GETHOSTBYNAME_R_3)
-    he = gethostbyname_r(hostname, h,  &buffer);
-    *err = h_errno;
+    wxUnusedVar(var);
+    *err = gethostbyname_r(hostname, h,  &buffer);
+    he = h;
 #elif defined(HAVE_GETHOSTBYNAME)
     wxLOCK_GETBY_MUTEX(name);
 
@@ -304,8 +305,9 @@ hostent *wxGethostbyaddr_r(const char *addr_buf,
 #elif defined(HAVE_FUNC_GETHOSTBYADDR_R_5)
     he = gethostbyaddr_r(addr_buf, buf_size, proto, h, buffer, size, err);
 #elif defined(HAVE_FUNC_GETHOSTBYADDR_R_3)
-    he = gethostbyaddr_r(addr_buf, buf_size, proto, h, buffer);
-    *err = h_errno;
+    wxUnusedVar(size);
+    *err = gethostbyaddr_r(addr_buf, buf_size, proto, h, &buffer);
+    he = h;
 #elif defined(HAVE_GETHOSTBYADDR)
     wxLOCK_GETBY_MUTEX(addr);
 
@@ -397,6 +399,7 @@ servent *wxGetservbyname_r(const char *port,
 #elif defined(HAVE_FUNC_GETSERVBYNAME_R_5)
     se = getservbyname_r(port, protocol, serv, buffer, size);
 #elif defined(HAVE_FUNC_GETSERVBYNAME_R_4)
+    wxUnusedVar(size);
     if ( getservbyname_r(port, protocol, serv, &buffer) != 0 )
         return NULL;
 #elif defined(HAVE_GETSERVBYNAME)