svn commit: trunk/uClibc/libc/inet/rpc
vapier at uclibc.org
vapier at uclibc.org
Mon Jan 29 02:04:52 UTC 2007
Author: vapier
Date: 2007-01-28 18:04:51 -0800 (Sun, 28 Jan 2007)
New Revision: 17610
Log:
sync some fixes from glibc
Modified:
trunk/uClibc/libc/inet/rpc/rexec.c
Changeset:
Modified: trunk/uClibc/libc/inet/rpc/rexec.c
===================================================================
--- trunk/uClibc/libc/inet/rpc/rexec.c 2007-01-29 01:43:26 UTC (rev 17609)
+++ trunk/uClibc/libc/inet/rpc/rexec.c 2007-01-29 02:04:51 UTC (rev 17610)
@@ -87,7 +87,7 @@
snprintf(servbuff, sizeof(servbuff), "%d", ntohs(rport));
servbuff[sizeof(servbuff) - 1] = '\0';
- memset(&hints, 0, sizeof(hints));
+ memset(&hints, '\0', sizeof(hints));
hints.ai_family = af;
hints.ai_socktype = SOCK_STREAM;
hints.ai_flags = AI_CANONNAME;
@@ -104,6 +104,8 @@
}
else{
*ahost = NULL;
+ __set_errno (ENOENT);
+ return -1;
}
ruserpass(res0->ai_canonname, &name, &pass);
retry:
@@ -127,7 +129,8 @@
port = 0;
} else {
char num[32];
- int s2, sa2len;
+ int s2;
+ socklen_t sa2len;
s2 = socket(res0->ai_family, res0->ai_socktype, 0);
if (s2 < 0) {
@@ -153,7 +156,8 @@
(void) sprintf(num, "%u", port);
(void) write(s, num, strlen(num)+1);
{ socklen_t len = sizeof (from);
- s3 = accept(s2, (struct sockaddr *)&from, &len);
+ s3 = TEMP_FAILURE_RETRY (accept(s2, (struct sockaddr *)&from,
+ &len));
close(s2);
if (s3 < 0) {
perror("accept");
More information about the uClibc-cvs
mailing list