]> The Tcpdump Group git mirrors - libpcap/commitdiff
-Wall -Werror clean.
authoritojun <itojun>
Sat, 3 Jun 2000 16:29:42 +0000 (16:29 +0000)
committeritojun <itojun>
Sat, 3 Jun 2000 16:29:42 +0000 (16:29 +0000)
gencode.c
grammar.y

index 4dcdbaa6702f9df57d18f591acd3aef19c9c9e52..ea2a9cb3c19092ed643344f94d4877433e25c966 100644 (file)
--- a/gencode.c
+++ b/gencode.c
@@ -21,7 +21,7 @@
  */
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /tcpdump/master/libpcap/gencode.c,v 1.109 2000-04-27 11:16:54 itojun Exp $ (LBL)";
+    "@(#) $Header: /tcpdump/master/libpcap/gencode.c,v 1.110 2000-06-03 16:29:42 itojun Exp $ (LBL)";
 #endif
 
 #include <sys/types.h>
@@ -154,7 +154,9 @@ static struct block *gen_host(bpf_u_int32, bpf_u_int32, int, int);
 #ifdef INET6
 static struct block *gen_host6(struct in6_addr *, struct in6_addr *, int, int);
 #endif
+#ifndef INET6
 static struct block *gen_gateway(const u_char *, bpf_u_int32 **, int, int);
+#endif
 static struct block *gen_ipfrag(void);
 static struct block *gen_portatom(int, bpf_int32);
 #ifdef INET6
@@ -1062,8 +1064,6 @@ gen_host6(addr, mask, proto, dir)
        int proto;
        int dir;
 {
-       struct block *b0, *b1;
-
        switch (proto) {
 
        case Q_DEFAULT:
@@ -1134,6 +1134,7 @@ gen_host6(addr, mask, proto, dir)
 }
 #endif /*INET6*/
 
+#ifndef INET6
 static struct block *
 gen_gateway(eaddr, alist, proto, dir)
        const u_char *eaddr;
@@ -1172,6 +1173,7 @@ gen_gateway(eaddr, alist, proto, dir)
        bpf_error("illegal modifier of 'gateway'");
        /* NOTREACHED */
 }
+#endif
 
 struct block *
 gen_proto_abbrev(proto)
@@ -1528,12 +1530,15 @@ lookup_proto(name, proto)
        return v;
 }
 
+#if 0
 struct stmt *
 gen_joinsp(s, n)
        struct stmt **s;
        int n;
 {
+       return NULL;
 }
+#endif
 
 struct block *
 gen_protochain(v, proto, dir)
@@ -1545,7 +1550,7 @@ gen_protochain(v, proto, dir)
        return gen_proto(v, proto, dir);
 #else
        struct block *b0, *b;
-       struct slist *s[100], *sp;
+       struct slist *s[100];
        int fix2, fix3, fix4, fix5;
        int ahcheck, again, end;
        int i, max;
@@ -1966,8 +1971,10 @@ gen_scode(name, q)
        int dir = q.dir;
        int tproto;
        u_char *eaddr;
-       bpf_u_int32 mask, addr, **alist;
-#ifdef INET6
+       bpf_u_int32 mask, addr;
+#ifndef INET6
+       bpf_u_int32 **alist;
+#else
        int tproto6;
        struct sockaddr_in *sin;
        struct sockaddr_in6 *sin6;
index 22e6948eadb6b31b42d0836b283cbab91e8b27cf..fab97e55fbfd4cd289176c153a74143cb9ceb211 100644 (file)
--- a/grammar.y
+++ b/grammar.y
  */
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /tcpdump/master/libpcap/grammar.y,v 1.57 1999-10-19 15:18:30 itojun Exp $ (LBL)";
+    "@(#) $Header: /tcpdump/master/libpcap/grammar.y,v 1.58 2000-06-03 16:29:43 itojun Exp $ (LBL)";
 #endif
 
 #include <sys/types.h>
 #include <sys/time.h>
 #include <sys/socket.h>
+#include <stdlib.h>
 
 #if __STDC__
 struct mbuf;