math.h: make __FLOAT_BITS and __DOUBLE_BITS C89
[musl] / src / network / gethostbyname2_r.c
index 49e4e53..27eb080 100644 (file)
@@ -5,7 +5,7 @@
 #include <string.h>
 #include <netinet/in.h>
 #include <errno.h>
-#include <inttypes.h>
+#include <stdint.h>
 
 int gethostbyname2_r(const char *name, int af,
        struct hostent *h, char *buf, size_t buflen,
@@ -30,7 +30,6 @@ int gethostbyname2_r(const char *name, int af,
                buflen -= sizeof(char *)-i;
        }
 
-       getaddrinfo(name, 0, &hint, &ai);
        switch (getaddrinfo(name, 0, &hint, &ai)) {
        case EAI_NONAME:
                *err = HOST_NOT_FOUND;