Ver Fonte

Add netdb bits to include hostent.h_addr

Jeremy Soller há 6 anos atrás
pai
commit
c6f2b30738
2 ficheiros alterados com 7 adições e 0 exclusões
  1. 6 0
      include/bits/netdb.h
  2. 1 0
      src/header/netdb/cbindgen.toml

+ 6 - 0
include/bits/netdb.h

@@ -0,0 +1,6 @@
+#ifndef _BITS_NETDB_H
+#define _BITS_NETDB_H
+
+# define        h_addr  h_addr_list[0] /* Address, for backward compatibility.*/
+
+#endif /* _BITS_NETDB_H */

+ 1 - 0
src/header/netdb/cbindgen.toml

@@ -1,5 +1,6 @@
 sys_includes = ["sys/socket.h", "netinet/in.h"]
 include_guard = "_NETDB_H"
+trailer = "#include <bits/netdb.h>"
 language = "C"
 style = "Tag"