OSSP CVS Repository

ossp - Difference in ossp-pkg/l2/l2_ch_socket.c versions 1.20 and 1.21
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/l2/l2_ch_socket.c 1.20 -> 1.21

--- l2_ch_socket.c       2001/09/07 13:03:07     1.20
+++ l2_ch_socket.c       2001/09/10 06:41:59     1.21
@@ -49,8 +49,8 @@
     int             i             = 0;
     struct in_addr  IP4Addr;
     struct in6_addr IP6Addr;
-    char            *pszIndex     = NULL;    /* To index IPv6 validity */
-    char            *pszNextfield = -1;      /* For IPv6 address trans */
+    const char      *pszIndex     = NULL;    /* To index IPv6 validity */
+    char            *pszNextfield = "";      /* For IPv6 address trans */
 
     if (iFamily == AF_INET) {
         if (inet_aton(pszAddress, &IP4Addr)) {
@@ -136,12 +136,12 @@
 /* open channel */
 static l2_result_t hook_open(l2_context_t *ctx, l2_channel_t *ch)
 {
-    int                 i;
+    //FIXME int                 i;
     l2_ch_socket_t      *cfg = (l2_ch_socket_t *)ctx->vp;
     struct hostent      *pHostentry;
     struct sockaddr_in  IP4Localsock, IP4Sockaddr;
     struct sockaddr_in6 IP6Localsock, IP6Sockaddr;
-    struct in6_addr     *IP6Addr;
+    //FIXME struct in6_addr     *IP6Addr;
 
     /* make sure a target is configured */
     if (cfg->pszHost == NULL)
@@ -220,7 +220,7 @@
             IP6Sockaddr.sin6_port   = htons(cfg->iPort);
         }
         /* resolve host nominally */
-        else if (pHostentry = gethostbyname(cfg->pszHost) != NULL) {
+        else if ((pHostentry = gethostbyname(cfg->pszHost)) != NULL) {
             if (pHostentry->h_addrtype == AF_INET6) {
                 IP6Sockaddr.sin6_family = AF_INET6;
                 IP6Sockaddr.sin6_port   = htons(cfg->iPort);

CVSTrac 2.0.1