[kitten] push by debonis....@gmail.com - Fix for multiple definitions of socklen_t on 2013-07-03 14:10 GMT

1 view
Skip to first unread message

kit...@googlecode.com

unread,
Jul 3, 2013, 10:11:04 AM7/3/13
to kitten-...@googlegroups.com
Revision: e2d07589f9c0
Branch: default
Author: David DeBonis <dde...@sandia.gov>
Date: Wed Jul 3 07:10:27 2013
Log: Fix for multiple definitions of socklen_t
http://code.google.com/p/kitten/source/detail?r=e2d07589f9c0

Modified:
/include/lwip/sockets.h
/user/runtime2/pct/pct.c

=======================================
--- /include/lwip/sockets.h Wed Jun 26 15:02:29 2013
+++ /include/lwip/sockets.h Wed Jul 3 07:10:27 2013
@@ -81,8 +81,11 @@
#endif /* LWIP_IPV6 */
};

-/* BJK: Adding structures to support sendmsg/recvmsg */
+/* If your port already typedef's socklen_t, define SOCKLEN_T_DEFINED
+ to prevent this code from redefining it. */
+#if !defined(socklen_t) && !defined(SOCKLEN_T_DEFINED)
typedef u32_t socklen_t;
+#endif

struct iovec {
char * iov_base; /* Base address of iov data */
@@ -103,12 +106,6 @@
with this. */
};

-/* If your port already typedef's socklen_t, define SOCKLEN_T_DEFINED
- to prevent this code from redefining it. */
-#if !defined(socklen_t) && !defined(SOCKLEN_T_DEFINED)
-typedef u32_t socklen_t;
-#endif
-
/* Socket protocol types (TCP/UDP/RAW) */
#define SOCK_STREAM 1
#define SOCK_DGRAM 2
=======================================
--- /user/runtime2/pct/pct.c Mon Jul 1 11:38:23 2013
+++ /user/runtime2/pct/pct.c Wed Jul 3 07:10:27 2013
@@ -322,7 +322,6 @@
printf( "PIAPI:\n");
printf( "\tsample - %u of %u\n", sample->number, sample->total );
printf( "\ttime - %f\n", sample->time_sec+sample->time_usec/1000000.0 );
- printf( "\tpower - %f\n", sample->raw.watts );
printf( "\tenergy - %f\n", sample->energy );
}
#endif
Reply all
Reply to author
Forward
0 new messages