svn commit: trunk/uClibc/libc/inet/rpc

vapier at uclibc.org vapier at uclibc.org
Mon Jun 19 01:54:35 UTC 2006


Author: vapier
Date: 2006-06-18 18:54:33 -0700 (Sun, 18 Jun 2006)
New Revision: 15428

Log:
sync fix fixes from glibc

Modified:
   trunk/uClibc/libc/inet/rpc/rtime.c


Changeset:
Modified: trunk/uClibc/libc/inet/rpc/rtime.c
===================================================================
--- trunk/uClibc/libc/inet/rpc/rtime.c	2006-06-19 01:48:41 UTC (rev 15427)
+++ trunk/uClibc/libc/inet/rpc/rtime.c	2006-06-19 01:54:33 UTC (rev 15428)
@@ -1,3 +1,6 @@
+#if 0
+static char sccsid[] = "@(#)rtime.c	2.2 88/08/10 4.0 RPCSRC; from 1.8 88/02/08 SMI";
+#endif
 /*
  * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
  * unrestricted use provided that this legend is included on all tape
@@ -26,9 +29,6 @@
  * 2550 Garcia Avenue
  * Mountain View, California  94043
  */
-#if 0
-static char sccsid[] = "@(#)rtime.c	2.2 88/08/10 4.0 RPCSRC; from 1.8 88/02/08 SMI";
-#endif
 
 /*
  * Copyright (c) 1988 by Sun Microsystems, Inc.
@@ -89,9 +89,10 @@
   struct pollfd fd;
   int milliseconds;
   int res;
-  unsigned long thetime;
+  /* RFC 868 says the time is transmitted as a 32-bit value.  */
+  uint32_t thetime;
   struct sockaddr_in from;
-  int fromlen;
+  socklen_t fromlen;
   int type;
 
   if (timeout == NULL)
@@ -108,7 +109,7 @@
   if (type == SOCK_DGRAM)
     {
       res = sendto (s, (char *) &thetime, sizeof (thetime), 0,
-		    (struct sockaddr *) addrp, sizeof (*addrp));
+		      (struct sockaddr *) addrp, sizeof (*addrp));
       if (res < 0)
 	{
 	  do_close (s);
@@ -129,7 +130,7 @@
 	}
       fromlen = sizeof (from);
       res = recvfrom (s, (char *) &thetime, sizeof (thetime), 0,
-		      (struct sockaddr *) &from, &fromlen);
+			(struct sockaddr *) &from, &fromlen);
       do_close (s);
       if (res < 0)
 	return -1;
@@ -156,3 +157,4 @@
   timep->tv_usec = 0;
   return 0;
 }
+libc_hidden_def (rtime)




More information about the uClibc-cvs mailing list