[rtems commit] telnetd: Use socklen_t

Sebastian Huber sebh at rtems.org
Thu Sep 18 07:30:40 UTC 2014


Module:    rtems
Branch:    master
Commit:    15d7261bec989a58515e12878aaf5590c23cf9cf
Changeset: http://git.rtems.org/rtems/commit/?id=15d7261bec989a58515e12878aaf5590c23cf9cf

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Thu Sep 18 08:09:09 2014 +0200

telnetd: Use socklen_t

---

 cpukit/telnetd/telnetd.c |   10 ----------
 1 files changed, 0 insertions(+), 10 deletions(-)

diff --git a/cpukit/telnetd/telnetd.c b/cpukit/telnetd/telnetd.c
index 745ead7..70ccbe1 100644
--- a/cpukit/telnetd/telnetd.c
+++ b/cpukit/telnetd/telnetd.c
@@ -105,12 +105,7 @@ static char *grab_a_Connection(
 )
 {
   char *rval = 0;
-#if 0
   socklen_t size_adr = sizeof(srv->sin);
-#else
-  /* 4.6 doesn't have socklen_t */
-  uint32_t size_adr = sizeof(srv->sin);
-#endif
   int acp_sock;
 
   acp_sock = accept(des_socket,&srv->sa,&size_adr);
@@ -161,12 +156,7 @@ static int sockpeername(int sock, char *buf, int bufsz)
 {
   uni_sa peer;
   int    rval = sock < 0;
-#if 0
   socklen_t len  = sizeof(peer.sin);
-#else
-  /* 4.6 doesn't have socklen_t */
-  uint32_t len  = sizeof(peer.sin);
-#endif
 
   if ( !rval )
     rval = getpeername(sock, &peer.sa, &len);



More information about the vc mailing list