]> The Tcpdump Group git mirrors - tcpdump/commitdiff
whitespace
authoritojun <itojun>
Tue, 11 Jun 2002 17:13:36 +0000 (17:13 +0000)
committeritojun <itojun>
Tue, 11 Jun 2002 17:13:36 +0000 (17:13 +0000)
12 files changed:
missing/addrinfo.h
missing/addrsize.h
missing/bittypes.h
missing/getaddrinfo.c
missing/getnameinfo.c
missing/inet_aton.c
missing/inet_ntop.c
missing/inet_pton.c
missing/resolv6.h
missing/resolv_ext.h
missing/snprintf.c
missing/sockstorage.h

index 169c3242dd87ea970f654711dc2ae043fb98fdd3..1b5f92ecb86085a1a2643d585e086cef7de853cf 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1995, 1996, 1997, 1998, and 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -27,7 +27,7 @@
  * SUCH DAMAGE.
  */
 
-/* $Id: addrinfo.h,v 1.3 2000-10-24 00:56:52 fenner Exp $ */
+/* $Id: addrinfo.h,v 1.4 2002-06-11 17:13:36 itojun Exp $ */
 
 #ifndef HAVE_ADDRINFO
 
index 2880956f2453168ca6a7d36e23d7e9a3201540a0..13db4da9159dea7e3fede636322a7b863ed28a67 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  */
-#ifndef INADDRSZ 
+#ifndef INADDRSZ
 #define INADDRSZ 4             /* IPv4 T_A */
 #endif
 
 #ifndef IN6ADDRSZ
 #define IN6ADDRSZ      16      /* IPv6 T_AAAA */
-#endif 
+#endif
 
index 500f39fdc5e22795e0d9431c35430f2682f65f2f..577da9448ec37e15e921feae3a746cc87e3dfdd4 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -38,7 +38,7 @@ typedef unsigned int u_int8_t;
 
 #endif /* HAVE_U_INT8_T */
 
-#ifndef HAVE_U_INT16_T 
+#ifndef HAVE_U_INT16_T
 
 #if SIZEOF_SHORT == 2
 typedef unsigned short u_int16_t;
index 09d39f9e5678234463029788f01e30069dcdaf9e..458fe01410e1efb31e600c2f55a75baa77ad44c1 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
-#endif 
+#endif
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/getaddrinfo.c,v 1.10 2000-10-24 00:56:53 fenner Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/getaddrinfo.c,v 1.11 2002-06-11 17:13:37 itojun Exp $";
 #endif
 
 #include <sys/types.h>
@@ -76,11 +76,11 @@ static const char rcsid[] =
 
 #ifndef HAVE_U_INT32_T
 #include "bittypes.h"
-#endif 
+#endif
 
 #ifndef HAVE_SOCKADDR_STORAGE
 #include "sockstorage.h"
-#endif 
+#endif
 
 #ifdef NEED_ADDRINFO_H
 #include "addrinfo.h"
@@ -104,7 +104,7 @@ static const char in_addrany[] = { 0, 0, 0, 0 };
 static const char in6_addrany[] = {
        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
 };
-static const char in_loopback[] = { 127, 0, 0, 1 }; 
+static const char in_loopback[] = { 127, 0, 0, 1 };
 static const char in6_loopback[] = {
        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1
 };
@@ -122,7 +122,7 @@ static const struct afd {
        int a_socklen;
        int a_off;
        const char *a_addrany;
-       const char *a_loopback; 
+       const char *a_loopback;
        int a_scoped;
 } afdl [] = {
 #ifdef INET6
@@ -323,7 +323,7 @@ getaddrinfo(hostname, servname, hints, res)
        pai->ai_canonname = NULL;
        pai->ai_addr = NULL;
        pai->ai_next = NULL;
-       
+
        if (hostname == NULL && servname == NULL)
                return EAI_NONAME;
        if (hints) {
@@ -813,7 +813,7 @@ explore_numeric(pai, hostname, servname, res)
                        }
                        while (cur && cur->ai_next)
                                cur = cur->ai_next;
-               } else 
+               } else
                        ERR(EAI_FAMILY);        /*xxx*/
        }
 
@@ -948,7 +948,7 @@ get_name(addr, afd, res, numaddr, pai, servname)
                GET_AI(cur, afd, numaddr);
                GET_PORT(cur, servname);
        }
-       
+
 #ifdef USE_GETIPNODEBY
        if (hp)
                freehostent(hp);
index d5e06391d8d20f1d5b6d4c84642ca1bbf3c0819d..9ea76b48f0e8a710b2f12970d5a51056513efac9 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
-#endif 
+#endif
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/getnameinfo.c,v 1.8 2000-10-24 00:56:53 fenner Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/getnameinfo.c,v 1.9 2002-06-11 17:13:37 itojun Exp $";
 #endif
 
 #include <sys/types.h>
@@ -124,7 +124,7 @@ getnameinfo(sa, salen, host, hostlen, serv, servlen, flags)
        if (sa->sa_len != salen)
                return ENI_SALEN;
 #endif
-       
+
        family = sa->sa_family;
        for (i = 0; afdl[i].a_af; i++)
                if (afdl[i].a_af == family) {
@@ -132,11 +132,11 @@ getnameinfo(sa, salen, host, hostlen, serv, servlen, flags)
                        goto found;
                }
        return ENI_FAMILY;
-       
+
  found:
        if (salen != afd->a_socklen)
                return ENI_SALEN;
-       
+
        port = ((struct sockinet *)sa)->si_port; /* network byte order */
        addr = (char *)sa + afd->a_off;
 
@@ -174,7 +174,7 @@ getnameinfo(sa, salen, host, hostlen, serv, servlen, flags)
                        flags |= NI_NUMERICHOST;
                v4a >>= IN_CLASSA_NSHIFT;
                if (v4a == 0)
-                       flags |= NI_NUMERICHOST;                        
+                       flags |= NI_NUMERICHOST;
                break;
 #ifdef INET6
        case AF_INET6:
index 0dbe9924573b34db09fd31e751d7720f0d304602..89cca84a1459e736996390b016d5757a664cb188 100644 (file)
@@ -2,27 +2,27 @@
  * Copyright (c) 1995, 1996, 1997 Kungliga Tekniska Högskolan
  * (Royal Institute of Technology, Stockholm, Sweden).
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
- * 
+ *
  * 1. Redistributions of source code must retain the above copyright
  *    notice, this list of conditions and the following disclaimer.
- * 
+ *
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * 3. All advertising materials mentioning features or use of this software
  *    must display the following acknowledgement:
  *      This product includes software developed by the Kungliga Tekniska
  *      Högskolan and its contributors.
- * 
+ *
  * 4. Neither the name of the Institute nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  * SUCH DAMAGE.
  */
 
-/* $Id: inet_aton.c,v 1.2 2000-01-09 21:35:45 fenner Exp $ */
+/* $Id: inet_aton.c,v 1.3 2002-06-11 17:13:38 itojun Exp $ */
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_aton.c,v 1.2 2000-01-09 21:35:45 fenner Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_aton.c,v 1.3 2002-06-11 17:13:38 itojun Exp $";
 #endif
 
 #include <sys/types.h>
index b0f4e4447c6599f7d8c464c1358316c32c53333d..9a68caaab8b380db3aa9668e6b5487f8782aa0e7 100644 (file)
@@ -2,27 +2,27 @@
  * Copyright (c) 1999 Kungliga Tekniska Högskolan
  * (Royal Institute of Technology, Stockholm, Sweden).
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
- * 
+ *
  * 1. Redistributions of source code must retain the above copyright
  *    notice, this list of conditions and the following disclaimer.
- * 
+ *
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * 3. All advertising materials mentioning features or use of this software
  *    must display the following acknowledgement:
  *      This product includes software developed by the Kungliga Tekniska
  *      Högskolan and its contributors.
- * 
+ *
  * 4. Neither the name of the Institute nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  * SUCH DAMAGE.
  */
 
-/* $Id: inet_ntop.c,v 1.3 2000-01-09 21:35:45 fenner Exp $ */
+/* $Id: inet_ntop.c,v 1.4 2002-06-11 17:13:38 itojun Exp $ */
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_ntop.c,v 1.3 2000-01-09 21:35:45 fenner Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_ntop.c,v 1.4 2002-06-11 17:13:38 itojun Exp $";
 #endif
 
 #include <stdio.h>
index a9b5c05dd58d15369461f473674bbd0f83c9ef98..e4cec2cdbba2784f835082d5740c75d00827a975 100644 (file)
@@ -2,27 +2,27 @@
  * Copyright (c) 1999 Kungliga Tekniska Högskolan
  * (Royal Institute of Technology, Stockholm, Sweden).
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
- * 
+ *
  * 1. Redistributions of source code must retain the above copyright
  *    notice, this list of conditions and the following disclaimer.
- * 
+ *
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * 3. All advertising materials mentioning features or use of this software
  *    must display the following acknowledgement:
  *      This product includes software developed by the Kungliga Tekniska
  *      Högskolan and its contributors.
- * 
+ *
  * 4. Neither the name of the Institute nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  * SUCH DAMAGE.
  */
 
-/* $Id: inet_pton.c,v 1.2 2000-01-09 21:35:46 fenner Exp $ */
+/* $Id: inet_pton.c,v 1.3 2002-06-11 17:13:38 itojun Exp $ */
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_pton.c,v 1.2 2000-01-09 21:35:46 fenner Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/inet_pton.c,v 1.3 2002-06-11 17:13:38 itojun Exp $";
 #endif
 
 #include <errno.h>
index b1d45c0c498a9dc7156c2d2e61cdfe24835f6849..ccee03e6c436221cb7d1008a8e078d5df64f38dc 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -33,4 +33,4 @@
  */
 #ifndef HAVE_RES_USE_INET6
 #define        RES_USE_INET6   0x80000000      /* use/map IPv6 in gethostbyname() */
-#endif 
+#endif
index c33ed7e179a98f75912f2a223b39ffe5f04f09d3..92c531d860cc76fc597b61e24b6fc3211b011180 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -29,7 +29,7 @@
 
 #ifndef MAXRESOLVSORT          /* XXX */
 #define        MAXRESOLVSORT           10      /* number of net to sort on */
-#endif 
+#endif
 
 #ifndef HAVE_RES_STATE_EXT
 struct __res_state_ext {
@@ -40,10 +40,10 @@ struct __res_state_ext {
                        struct in_addr ina;
 #ifdef INET6
                        struct in6_addr in6a;
-#endif 
+#endif
                } addr, mask;
        } sort_list[MAXRESOLVSORT];
 };
-#endif 
+#endif
 
 extern struct __res_state_ext _res_ext;
index 2b8368838f163f55889ce0ffb2df75d3b6f26c47..8e5994c464de8668c25b634f28f05a103b7b61ed 100644 (file)
@@ -2,22 +2,22 @@
  * Copyright (c) 1995-1999 Kungliga Tekniska Högskolan
  * (Royal Institute of Technology, Stockholm, Sweden).
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
- * 
+ *
  * 1. Redistributions of source code must retain the above copyright
  *    notice, this list of conditions and the following disclaimer.
- * 
+ *
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * 3. Neither the name of the Institute nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -31,7 +31,7 @@
  * SUCH DAMAGE.
  */
 
-/* $Id: snprintf.c,v 1.5 2001-01-12 10:14:40 guy Exp $ */
+/* $Id: snprintf.c,v 1.6 2002-06-11 17:13:39 itojun Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
@@ -39,7 +39,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-     "@(#) $Header: /tcpdump/master/tcpdump/missing/snprintf.c,v 1.5 2001-01-12 10:14:40 guy Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/missing/snprintf.c,v 1.6 2002-06-11 17:13:39 itojun Exp $";
 #endif
 
 #include <stdio.h>
@@ -214,7 +214,7 @@ append_number(struct state *state,
       state->s[-i-1] = state->s[-len+i];
       state->s[-len+i] = c;
     }
-    
+
   return 0;
 }
 
@@ -258,13 +258,13 @@ append_char(struct state *state,
   while(!(flags & minus_flag) && --width > 0)
     if((*state->append_char) (state, ' '))
       return 1;
-    
+
   if((*state->append_char) (state, arg))
     return 1;
   while((flags & minus_flag) && --width > 0)
     if((*state->append_char) (state, ' '))
       return 1;
-    
+
   return 0;
 }
 
@@ -313,7 +313,7 @@ xyzprintf (struct state *state, const char *char_format, va_list ap)
        else
          break;
       }
-      
+
       if((flags & space_flag) && (flags & plus_flag))
        flags ^= space_flag;
 
@@ -365,7 +365,7 @@ xyzprintf (struct state *state, const char *char_format, va_list ap)
        if (append_string(state,
                          va_arg(ap, unsigned char*),
                          width,
-                         prec, 
+                         prec,
                          flags))
          return -1;
        break;
index 557eb4df0aff97f172db091f39c1635d4c9e88c7..cbad1900412a7a43f5e3af3822f1ba844dad1a19 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright (C) 1999 WIDE Project.
  * All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 3. Neither the name of the project nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE