OSDN Git Service

mkostemp: fix implementation
[uclinux-h8/uClibc.git] / libc / inet / getaddrinfo.c
index 88bd745..168adb1 100644 (file)
@@ -51,8 +51,6 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
   If these license terms cause you a real problem, contact the author.  */
 
-#define __FORCE_GLIBC
-#include <features.h>
 #include <assert.h>
 #include <errno.h>
 #include <netdb.h>
@@ -283,7 +281,7 @@ gaih_local(const char *name, const struct gaih_service *service,
        ai->ai_protocol = req->ai_protocol;
        ai->ai_addrlen = sizeof(struct sockaddr_un);
        ai->ai_addr = (void *)ai + sizeof(struct addrinfo);
-#if SALEN
+#if 0 /* SALEN */
        ((struct sockaddr_un *)ai->ai_addr)->sun_len = sizeof(struct sockaddr_un);
 #endif /* SALEN */
 
@@ -310,7 +308,7 @@ gaih_local(const char *name, const struct gaih_service *service,
                char *buf = ((struct sockaddr_un *)ai->ai_addr)->sun_path;
 
                if (__path_search(buf, L_tmpnam, NULL, NULL, 0) != 0
-                || __gen_tempname(buf, __GT_NOCREATE, 0) != 0
+                || __gen_tempname(buf, __GT_NOCREATE, 0, 0) != 0
                ) {
                        return -EAI_SYSTEM;
                }
@@ -713,7 +711,7 @@ gaih_inet(const char *name, const struct gaih_service *service,
                                (*pai)->ai_protocol = st2->protocol;
                                (*pai)->ai_addrlen = socklen;
                                (*pai)->ai_addr = (void *) (*pai) + sizeof(struct addrinfo);
-#if defined SALEN
+#if 0 /* SALEN */
                                (*pai)->ai_addr->sa_len = socklen;
 #endif
                                (*pai)->ai_addr->sa_family = family;