]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Remove all storage class specifier 'register'
authorFrancois-Xavier Le Bail <[email protected]>
Wed, 13 Dec 2017 18:17:47 +0000 (19:17 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Wed, 13 Dec 2017 18:17:47 +0000 (19:17 +0100)
Let the compiler do the optimizations (or not) based on build options.

Avoid 'value has been optimized out' messages in gdb using '-O0'.

92 files changed:
addrtoname.c
addrtoname.h
ascii_strcasecmp.c
checksum.c
gmt2local.c
in_cksum.c
missing/getservent.c
missing/strlcat.c
missing/strlcpy.c
missing/strsep.c
netdissect.h
parsenfsfh.c
print-ah.c
print-ap1394.c
print-ascii.c
print-atalk.c
print-bfd.c
print-bootp.c
print-carp.c
print-cfm.c
print-chdlc.c
print-cnfp.c
print-decnet.c
print-domain.c
print-dvmrp.c
print-eap.c
print-egp.c
print-eigrp.c
print-enc.c
print-esp.c
print-ether.c
print-fddi.c
print-forces.c
print-fr.c
print-frag6.c
print-hsrp.c
print-icmp.c
print-icmp6.c
print-igmp.c
print-igrp.c
print-ip.c
print-ip6.c
print-ip6opts.c
print-ipcomp.c
print-ipfc.c
print-ipx.c
print-juniper.c
print-krb.c
print-ldp.c
print-llc.c
print-lldp.c
print-lmp.c
print-lspping.c
print-lwres.c
print-mpcp.c
print-nfs.c
print-ntp.c
print-ospf.c
print-ospf6.c
print-pflog.c
print-pgm.c
print-pim.c
print-ppp.c
print-pppoe.c
print-radius.c
print-resp.c
print-rip.c
print-ripng.c
print-rpki-rtr.c
print-rrcp.c
print-rsvp.c
print-rt6.c
print-rx.c
print-sl.c
print-sll.c
print-slow.c
print-snmp.c
print-sunrpc.c
print-symantec.c
print-syslog.c
print-tcp.c
print-tftp.c
print-timed.c
print-token.c
print-udp.c
print-usb.c
print-vjc.c
print-vqp.c
print-vrrp.c
print-wb.c
tcpdump.c
util-print.c

index 003ce51211eb5d087925b0b56c60769fb95b7e45..9d5c88ccf1bc9cab62aecc58b608caf3cb97c606 100644 (file)
@@ -181,9 +181,9 @@ static struct protoidmem protoidtable[HASHNAMESIZE];
 const char *
 intoa(uint32_t addr)
 {
-       register char *cp;
-       register u_int byte;
-       register int n;
+       char *cp;
+       u_int byte;
+       int n;
        static char buf[sizeof(".xxx.xxx.xxx.xxx")];
 
        NTOHL(addr);
@@ -236,7 +236,7 @@ extern cap_channel_t *capdns;
 const char *
 getname(netdissect_options *ndo, const u_char *ap)
 {
-       register struct hostent *hp;
+       struct hostent *hp;
        uint32_t addr;
        struct hnamemem *p;
 
@@ -294,7 +294,7 @@ getname(netdissect_options *ndo, const u_char *ap)
 const char *
 getname6(netdissect_options *ndo, const u_char *ap)
 {
-       register struct hostent *hp;
+       struct hostent *hp;
        union {
                struct in6_addr addr;
                struct for_hash_addr {
@@ -303,7 +303,7 @@ getname6(netdissect_options *ndo, const u_char *ap)
                } addra;
        } addr;
        struct h6namemem *p;
-       register const char *cp;
+       const char *cp;
        char ntop_buf[INET6_ADDRSTRLEN];
 
        memcpy(&addr, ap, sizeof(addr));
@@ -360,7 +360,7 @@ static const char hex[16] = {
 static inline struct enamemem *
 lookup_emem(netdissect_options *ndo, const u_char *ep)
 {
-       register u_int i, j, k;
+       u_int i, j, k;
        struct enamemem *tp;
 
        k = (ep[0] << 8) | ep[1];
@@ -391,11 +391,11 @@ lookup_emem(netdissect_options *ndo, const u_char *ep)
  */
 
 static inline struct bsnamemem *
-lookup_bytestring(netdissect_options *ndo, register const u_char *bs,
+lookup_bytestring(netdissect_options *ndo, const u_char *bs,
                  const unsigned int nlen)
 {
        struct bsnamemem *tp;
-       register u_int i, j, k;
+       u_int i, j, k;
 
        if (nlen >= 6) {
                k = (bs[0] << 8) | bs[1];
@@ -439,10 +439,10 @@ lookup_bytestring(netdissect_options *ndo, register const u_char *bs,
 /* Find the hash node that corresponds the NSAP 'nsap' */
 
 static inline struct enamemem *
-lookup_nsap(netdissect_options *ndo, register const u_char *nsap,
-           register u_int nsap_length)
+lookup_nsap(netdissect_options *ndo, const u_char *nsap,
+           u_int nsap_length)
 {
-       register u_int i, j, k;
+       u_int i, j, k;
        struct enamemem *tp;
        const u_char *ensap;
 
@@ -486,7 +486,7 @@ lookup_nsap(netdissect_options *ndo, register const u_char *nsap,
 static inline struct protoidmem *
 lookup_protoid(netdissect_options *ndo, const u_char *pi)
 {
-       register u_int i, j;
+       u_int i, j;
        struct protoidmem *tp;
 
        /* 5 octets won't be aligned */
@@ -510,11 +510,11 @@ lookup_protoid(netdissect_options *ndo, const u_char *pi)
 }
 
 const char *
-etheraddr_string(netdissect_options *ndo, register const u_char *ep)
+etheraddr_string(netdissect_options *ndo, const u_char *ep)
 {
-       register int i;
-       register char *cp;
-       register struct enamemem *tp;
+       int i;
+       char *cp;
+       struct enamemem *tp;
        int oui;
        char buf[BUFSIZE];
 
@@ -559,9 +559,9 @@ const char *
 le64addr_string(netdissect_options *ndo, const u_char *ep)
 {
        const unsigned int len = 8;
-       register u_int i;
-       register char *cp;
-       register struct bsnamemem *tp;
+       u_int i;
+       char *cp;
+       struct bsnamemem *tp;
        char buf[BUFSIZE];
 
        tp = lookup_bytestring(ndo, ep, len);
@@ -589,9 +589,9 @@ const char *
 linkaddr_string(netdissect_options *ndo, const u_char *ep,
                const unsigned int type, const unsigned int len)
 {
-       register u_int i;
-       register char *cp;
-       register struct bsnamemem *tp;
+       u_int i;
+       char *cp;
+       struct bsnamemem *tp;
 
        if (len == 0)
                return ("<empty>");
@@ -623,9 +623,9 @@ linkaddr_string(netdissect_options *ndo, const u_char *ep,
 const char *
 etherproto_string(netdissect_options *ndo, u_short port)
 {
-       register char *cp;
-       register struct hnamemem *tp;
-       register uint32_t i = port;
+       char *cp;
+       struct hnamemem *tp;
+       uint32_t i = port;
        char buf[sizeof("0000")];
 
        for (tp = &eprototable[i & (HASHNAMESIZE-1)]; tp->nxt; tp = tp->nxt)
@@ -651,11 +651,11 @@ etherproto_string(netdissect_options *ndo, u_short port)
 #define ISONSAP_MAX_LENGTH 20
 const char *
 isonsap_string(netdissect_options *ndo, const u_char *nsap,
-              register u_int nsap_length)
+              u_int nsap_length)
 {
-       register u_int nsap_idx;
-       register char *cp;
-       register struct enamemem *tp;
+       u_int nsap_idx;
+       char *cp;
+       struct enamemem *tp;
 
        if (nsap_length < 1 || nsap_length > ISONSAP_MAX_LENGTH)
                return ("isonsap_string: illegal length");
@@ -683,8 +683,8 @@ isonsap_string(netdissect_options *ndo, const u_char *nsap,
 const char *
 tcpport_string(netdissect_options *ndo, u_short port)
 {
-       register struct hnamemem *tp;
-       register uint32_t i = port;
+       struct hnamemem *tp;
+       uint32_t i = port;
        char buf[sizeof("00000")];
 
        for (tp = &tporttable[i & (HASHNAMESIZE-1)]; tp->nxt; tp = tp->nxt)
@@ -702,10 +702,10 @@ tcpport_string(netdissect_options *ndo, u_short port)
 }
 
 const char *
-udpport_string(netdissect_options *ndo, register u_short port)
+udpport_string(netdissect_options *ndo, u_short port)
 {
-       register struct hnamemem *tp;
-       register uint32_t i = port;
+       struct hnamemem *tp;
+       uint32_t i = port;
        char buf[sizeof("00000")];
 
        for (tp = &uporttable[i & (HASHNAMESIZE-1)]; tp->nxt; tp = tp->nxt)
@@ -725,9 +725,9 @@ udpport_string(netdissect_options *ndo, register u_short port)
 const char *
 ipxsap_string(netdissect_options *ndo, u_short port)
 {
-       register char *cp;
-       register struct hnamemem *tp;
-       register uint32_t i = port;
+       char *cp;
+       struct hnamemem *tp;
+       uint32_t i = port;
        char buf[sizeof("0000")];
 
        for (tp = &ipxsaptable[i & (HASHNAMESIZE-1)]; tp->nxt; tp = tp->nxt)
@@ -754,8 +754,8 @@ static void
 init_servarray(netdissect_options *ndo)
 {
        struct servent *sv;
-       register struct hnamemem *table;
-       register int i;
+       struct hnamemem *table;
+       int i;
        char buf[sizeof("0000000000")];
 
        while ((sv = getservent()) != NULL) {
@@ -814,8 +814,8 @@ static const struct eproto {
 static void
 init_eprotoarray(netdissect_options *ndo)
 {
-       register int i;
-       register struct hnamemem *table;
+       int i;
+       struct hnamemem *table;
 
        for (i = 0; eproto_db[i].s; i++) {
                int j = htons(eproto_db[i].p) & (HASHNAMESIZE-1);
@@ -847,8 +847,8 @@ static const struct protoidlist {
 static void
 init_protoidarray(netdissect_options *ndo)
 {
-       register int i;
-       register struct protoidmem *tp;
+       int i;
+       struct protoidmem *tp;
        const struct protoidlist *pl;
        u_char protoid[5];
 
@@ -901,13 +901,13 @@ static const struct etherlist {
 static void
 init_etherarray(netdissect_options *ndo)
 {
-       register const struct etherlist *el;
-       register struct enamemem *tp;
+       const struct etherlist *el;
+       struct enamemem *tp;
 #ifdef USE_ETHER_NTOHOST
        char name[256];
 #else
-       register struct pcap_etherent *ep;
-       register FILE *fp;
+       struct pcap_etherent *ep;
+       FILE *fp;
 
        /* Suck in entire ethers file */
        fp = fopen(PCAP_ETHERS_FILE, "r");
@@ -1166,8 +1166,8 @@ static const struct tok ipxsap_db[] = {
 static void
 init_ipxsaparray(netdissect_options *ndo)
 {
-       register int i;
-       register struct hnamemem *table;
+       int i;
+       struct hnamemem *table;
 
        for (i = 0; ipxsap_db[i].s != NULL; i++) {
                int j = htons(ipxsap_db[i].v) & (HASHNAMESIZE-1);
@@ -1209,7 +1209,7 @@ init_addrtoname(netdissect_options *ndo, uint32_t localnet, uint32_t mask)
 const char *
 dnaddr_string(netdissect_options *ndo, u_short dnaddr)
 {
-       register struct hnamemem *tp;
+       struct hnamemem *tp;
 
        for (tp = &dnaddrtable[dnaddr & (HASHNAMESIZE-1)]; tp->nxt != NULL;
             tp = tp->nxt)
@@ -1230,7 +1230,7 @@ dnaddr_string(netdissect_options *ndo, u_short dnaddr)
 struct hnamemem *
 newhnamemem(netdissect_options *ndo)
 {
-       register struct hnamemem *p;
+       struct hnamemem *p;
        static struct hnamemem *ptr = NULL;
        static u_int num = 0;
 
@@ -1249,7 +1249,7 @@ newhnamemem(netdissect_options *ndo)
 struct h6namemem *
 newh6namemem(netdissect_options *ndo)
 {
-       register struct h6namemem *p;
+       struct h6namemem *p;
        static struct h6namemem *ptr = NULL;
        static u_int num = 0;
 
index c3019194e041c3df204d7409f9562c167b7828f5..8a37d3d59629cb519547b58358b8d9c8ef5da16d 100644 (file)
@@ -45,7 +45,7 @@ extern const char *le64addr_string(netdissect_options *, const u_char *);
 extern const char *etherproto_string(netdissect_options *, u_short);
 extern const char *tcpport_string(netdissect_options *, u_short);
 extern const char *udpport_string(netdissect_options *, u_short);
-extern const char *isonsap_string(netdissect_options *, const u_char *, register u_int);
+extern const char *isonsap_string(netdissect_options *, const u_char *, u_int);
 extern const char *dnaddr_string(netdissect_options *, u_short);
 extern const char *ipxsap_string(netdissect_options *, u_short);
 extern const char *getname(netdissect_options *, const u_char *);
index b8decf141b05f8ab88e0366e7d1cd9ecd2ad2e72..090f75869ef8fecb7a46e36b50bf4b60a068a58f 100644 (file)
@@ -58,7 +58,7 @@ static const unsigned char charmap[] = {
 int
 ascii_strcasecmp(const char *s1, const char *s2)
 {
-       register const unsigned char *cm = charmap,
+       const unsigned char *cm = charmap,
                        *us1 = (const unsigned char *)s1,
                        *us2 = (const unsigned char *)s2;
 
@@ -69,9 +69,9 @@ ascii_strcasecmp(const char *s1, const char *s2)
 }
 
 int
-ascii_strncasecmp(const char *s1, const char *s2, register size_t n)
+ascii_strncasecmp(const char *s1, const char *s2, size_t n)
 {
-       register const unsigned char *cm = charmap,
+       const unsigned char *cm = charmap,
                        *us1 = (const unsigned char *)s1,
                        *us2 = (const unsigned char *)s2;
 
index a48a147f35c2f8d2916e31320286b96c60c28a28..ca98ee87573be4756d43a33e92c0d1314fb57a59 100644 (file)
@@ -90,8 +90,8 @@ static void
 init_crc10_table(void)
 {
 #define CRC10_POLYNOMIAL 0x633
-    register int i, j;
-    register uint16_t accum;
+    int i, j;
+    uint16_t accum;
     uint16_t verify_crc10_table[256];
 
     for ( i = 0;  i < 256;  i++ )
@@ -112,7 +112,7 @@ init_crc10_table(void)
 uint16_t
 verify_crc10_cksum(uint16_t accum, const u_char *p, int length)
 {
-    register int i;
+    int i;
 
     for ( i = 0;  i < length;  i++ )
     {
index d6cd93b8532bf31543884b90f2e52d089bae5f09..4d392207997b68d317956342ee20dbb287b1daf4 100644 (file)
@@ -40,8 +40,8 @@
 int32_t
 gmt2local(time_t t)
 {
-       register int dt, dir;
-       register struct tm *gmt, *loc;
+       int dt, dir;
+       struct tm *gmt, *loc;
        struct tm sgmt;
 
        if (t == 0)
index e9bed2287ae626f9e263e09c51170a6738f7fea7..aa9ab3bddc696df8d83409c61602c48efcb4fa5a 100644 (file)
@@ -56,9 +56,9 @@
 uint16_t
 in_cksum(const struct cksum_vec *vec, int veclen)
 {
-       register const uint16_t *w;
-       register int sum = 0;
-       register int mlen = 0;
+       const uint16_t *w;
+       int sum = 0;
+       int mlen = 0;
        int byte_swapped = 0;
 
        union {
index 48b7465ca2be243fd8e1845f9f719aa2177e9b2b..043b82852ad6989378aca22c026850e0183f955e 100644 (file)
@@ -96,7 +96,7 @@ struct servent *
 getservent(void)
 {
     char *p;
-    register char *cp, **q;
+    char *cp, **q;
 
     if (servf == NULL && (servf = fopen(etc_path(__PATH_SERVICES), "r")) == NULL)
         return (NULL);
index 405493545b51e17dab77147eee1c6b80c4db33d2..f41207be3630f78864a58d6cda07773d2811cba1 100644 (file)
@@ -47,9 +47,9 @@
 size_t
 strlcat(char *dst, const char *src, size_t siz)
 {
-       register char *d = dst;
-       register const char *s = src;
-       register size_t n = siz;
+       char *d = dst;
+       const char *s = src;
+       size_t n = siz;
        size_t dlen;
 
        /* Find the end of dst and adjust bytes left but don't go past end */
index 24dcca67667fcca6a2a483c1dadd3a40f7c3353f..2dc51b96295ae3e00f1f80a4aefbf8a3e6dc3cdf 100644 (file)
@@ -46,9 +46,9 @@
 size_t
 strlcpy(char *dst, const char *src, size_t siz)
 {
-       register char *d = dst;
-       register const char *s = src;
-       register size_t n = siz;
+       char *d = dst;
+       const char *s = src;
+       size_t n = siz;
 
        /* Copy as many bytes as will fit */
        if (n != 0 && --n != 0) {
index 2c17275f33914d764182cd8e005b54d33e8c07ec..05f10bccff92d54fee0d7e1d6215ebb4394ba6d3 100644 (file)
@@ -55,9 +55,9 @@
 char *
 strsep(char **stringp, const char *delim)
 {
-       register char *s;
-       register const char *spanp;
-       register int c, sc;
+       char *s;
+       const char *spanp;
+       int c, sc;
        char *tok;
 
        if ((s = *stringp) == NULL)
index 11907ea98e9d485cd64e5ca89c7d5b30c590b803..70c821d920f6179960a5f611565f024f6a0831e5 100644 (file)
@@ -210,7 +210,7 @@ struct netdissect_options {
 
   /* pointer to void function to output stuff */
   void (*ndo_default_print)(netdissect_options *,
-                           register const u_char *bp, register u_int length);
+                           const u_char *bp, u_int length);
 
   /* pointer to function to do regular output */
   int  (*ndo_printf)(netdissect_options *,
@@ -502,7 +502,7 @@ struct lladdr_info {
 /* The printer routines. */
 
 extern void aarp_print(netdissect_options *, const u_char *, u_int);
-extern int ah_print(netdissect_options *, register const u_char *);
+extern int ah_print(netdissect_options *, const u_char *);
 extern void ahcp_print(netdissect_options *, const u_char *, const u_int);
 extern void aodv_print(netdissect_options *, const u_char *, u_int, int);
 extern void aoe_print(netdissect_options *, const u_char *, const u_int);
@@ -520,7 +520,7 @@ extern void calm_fast_print(netdissect_options *, const u_char *, u_int, const s
 extern void carp_print(netdissect_options *, const u_char *, u_int, int);
 extern void cdp_print(netdissect_options *, const u_char *, u_int, u_int);
 extern void cfm_print(netdissect_options *, const u_char *, u_int);
-extern u_int chdlc_print(netdissect_options *, register const u_char *, u_int);
+extern u_int chdlc_print(netdissect_options *, const u_char *, u_int);
 extern void cisco_autorp_print(netdissect_options *, const u_char *, u_int);
 extern void cnfp_print(netdissect_options *, const u_char *);
 extern void dccp_print(netdissect_options *, const u_char *, const u_char *, u_int);
@@ -537,7 +537,7 @@ extern u_int ether_print(netdissect_options *, const u_char *, u_int, u_int, voi
 extern int ethertype_print(netdissect_options *, u_short, const u_char *, u_int, u_int, const struct lladdr_info *, const struct lladdr_info *);
 extern u_int fddi_print(netdissect_options *, const u_char *, u_int, u_int);
 extern void forces_print(netdissect_options *, const u_char *, u_int);
-extern u_int fr_print(netdissect_options *, register const u_char *, u_int);
+extern u_int fr_print(netdissect_options *, const u_char *, u_int);
 extern int frag6_print(netdissect_options *, const u_char *, const u_char *);
 extern void ftp_print(netdissect_options *, const u_char *, u_int);
 extern void geneve_print(netdissect_options *, const u_char *, u_int);
@@ -559,7 +559,7 @@ extern void ip6_print(netdissect_options *, const u_char *, u_int);
 extern void ipN_print(netdissect_options *, const u_char *, u_int);
 extern void ip_print(netdissect_options *, const u_char *, u_int);
 extern void ip_print_inner(netdissect_options *, const u_char *, u_int, u_int nh, const u_char *);
-extern void ipcomp_print(netdissect_options *, register const u_char *);
+extern void ipcomp_print(netdissect_options *, const u_char *);
 extern void ipx_netbios_print(netdissect_options *, const u_char *, u_int);
 extern void ipx_print(netdissect_options *, const u_char *, u_int);
 extern void isakmp_print(netdissect_options *, const u_char *, u_int, const u_char *);
@@ -581,7 +581,7 @@ extern void lwapp_data_print(netdissect_options *, const u_char *, u_int);
 extern void lwres_print(netdissect_options *, const u_char *, u_int);
 extern void m3ua_print(netdissect_options *, const u_char *, const u_int);
 extern void medsa_print(netdissect_options *, const u_char *, u_int, u_int, const struct lladdr_info *, const struct lladdr_info *);
-extern u_int mfr_print(netdissect_options *, register const u_char *, u_int);
+extern u_int mfr_print(netdissect_options *, const u_char *, u_int);
 extern void mobile_print(netdissect_options *, const u_char *, u_int);
 extern int mobility_print(netdissect_options *, const u_char *, const u_char *);
 extern void mpcp_print(netdissect_options *, const u_char *, u_int);
@@ -596,7 +596,7 @@ extern void netbeui_print(netdissect_options *, u_short, const u_char *, int);
 extern void nfsreply_print(netdissect_options *, const u_char *, u_int, const u_char *);
 extern void nfsreply_noaddr_print(netdissect_options *, const u_char *, u_int, const u_char *);
 extern void nfsreq_noaddr_print(netdissect_options *, const u_char *, u_int, const u_char *);
-extern const u_char * ns_nprint (netdissect_options *, register const u_char *, register const u_char *);
+extern const u_char * ns_nprint (netdissect_options *, const u_char *, const u_char *);
 extern void domain_print(netdissect_options *, const u_char *, u_int, int);
 extern void nsh_print(netdissect_options *ndo, const u_char *bp, u_int len);
 extern void ntp_print(netdissect_options *, const u_char *, u_int);
@@ -611,7 +611,7 @@ extern void otv_print(netdissect_options *, const u_char *, u_int);
 extern void pgm_print(netdissect_options *, const u_char *, u_int, const u_char *);
 extern void pim_print(netdissect_options *, const u_char *, u_int, const u_char *);
 extern void pimv1_print(netdissect_options *, const u_char *, u_int);
-extern u_int ppp_print(netdissect_options *, register const u_char *, u_int);
+extern u_int ppp_print(netdissect_options *, const u_char *, u_int);
 extern u_int pppoe_print(netdissect_options *, const u_char *, u_int);
 extern void pptp_print(netdissect_options *, const u_char *);
 extern int print_unknown_data(netdissect_options *, const u_char *, const char *, int);
@@ -626,7 +626,7 @@ extern void rrcp_print(netdissect_options *, const u_char *, u_int, const struct
 extern void rsvp_print(netdissect_options *, const u_char *, u_int);
 extern int rt6_print(netdissect_options *, const u_char *, const u_char *);
 extern void rtsp_print(netdissect_options *, const u_char *, u_int);
-extern void rx_print(netdissect_options *, register const u_char *, u_int, u_int, u_int, const u_char *);
+extern void rx_print(netdissect_options *, const u_char *, u_int, u_int, u_int, const u_char *);
 extern void sctp_print(netdissect_options *, const u_char *, const u_char *, u_int);
 extern void sflow_print(netdissect_options *, const u_char *, u_int);
 extern void sip_print(netdissect_options *, const u_char *, u_int);
@@ -647,8 +647,8 @@ extern void tipc_print(netdissect_options *, const u_char *, u_int, u_int);
 extern u_int token_print(netdissect_options *, const u_char *, u_int, u_int);
 extern void udld_print(netdissect_options *, const u_char *, u_int);
 extern void udp_print(netdissect_options *, const u_char *, u_int, const u_char *, int);
-extern int vjc_print(netdissect_options *, register const u_char *, u_short);
-extern void vqp_print(netdissect_options *, register const u_char *, register u_int);
+extern int vjc_print(netdissect_options *, const u_char *, u_short);
+extern void vqp_print(netdissect_options *, const u_char *, u_int);
 extern void vrrp_print(netdissect_options *, const u_char *, u_int, const u_char *, int);
 extern void vtp_print(netdissect_options *, const u_char *, u_int);
 extern void vxlan_gpe_print(netdissect_options *ndo, const u_char *bp, u_int len);
index 8f48e774d7668991a1326eaba05ff8cfbed96746..f5457917e59ae28459b5d0d6f30e40c0f797039d 100644 (file)
 static int is_UCX(const unsigned char *, u_int);
 
 void
-Parse_fh(register const unsigned char *fh, u_int len, my_fsid *fsidp,
+Parse_fh(const unsigned char *fh, u_int len, my_fsid *fsidp,
         uint32_t *inop,
         const char **osnamep, /* if non-NULL, return OS name here */
         const char **fsnamep, /* if non-NULL, return server fs name here (for VMS) */
         int ourself)   /* true if file handle was generated on this host */
 {
-       register const unsigned char *fhp = fh;
+       const unsigned char *fhp = fh;
        uint32_t temp;
        int fhtype = FHT_UNKNOWN;
        u_int i;
@@ -453,7 +453,7 @@ Parse_fh(register const unsigned char *fh, u_int len, my_fsid *fsidp,
 static int
 is_UCX(const unsigned char *fhp, u_int len)
 {
-       register u_int i;
+       u_int i;
        int seen_null = 0;
 
        /*
index 307fe0d35de043f6ea46ee330e77451646a47046..d47309bf171ca545f29b8f17532a8ae1907335d0 100644 (file)
@@ -35,9 +35,9 @@
 #include "extract.h"
 
 int
-ah_print(netdissect_options *ndo, register const u_char *bp)
+ah_print(netdissect_options *ndo, const u_char *bp)
 {
-       register const struct ah *ah;
+       const struct ah *ah;
        int sumlen;
 
        ah = (const struct ah *)bp;
index 869fbcb9b7145c3674b069d2f7e08486b758011f..4c463ada3a107f23cec76b726ae8059218526316 100644 (file)
@@ -56,9 +56,9 @@ fwaddr_string(netdissect_options *ndo, const u_char *addr)
 }
 
 static inline void
-ap1394_hdr_print(netdissect_options *ndo, register const u_char *bp, u_int length)
+ap1394_hdr_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
-       register const struct firewire_header *fp;
+       const struct firewire_header *fp;
        uint16_t firewire_type;
 
        fp = (const struct firewire_header *)bp;
index 2e5812e4c05eb49098c7b9de6d8730568ad07fee..14e50bd5e385447e08f6d22c350a4a10bc6b179e 100644 (file)
@@ -60,7 +60,7 @@ ascii_print(netdissect_options *ndo,
             const u_char *cp, u_int length)
 {
        u_int caplength;
-       register u_char s;
+       u_char s;
 
        caplength = (ndo->ndo_snapend >= cp) ? ndo->ndo_snapend - cp : 0;
        if (length > caplength)
@@ -93,13 +93,13 @@ ascii_print(netdissect_options *ndo,
 }
 
 void
-hex_and_ascii_print_with_offset(netdissect_options *ndo, register const char *ident,
-    register const u_char *cp, register u_int length, register u_int oset)
+hex_and_ascii_print_with_offset(netdissect_options *ndo, const char *ident,
+    const u_char *cp, u_int length, u_int oset)
 {
        u_int caplength;
-       register u_int i;
-       register int s1, s2;
-       register int nshorts;
+       u_int i;
+       int s1, s2;
+       int nshorts;
        char hexstuff[HEXDUMP_SHORTS_PER_LINE*HEXDUMP_HEXSTUFF_PER_SHORT+1], *hsp;
        char asciistuff[ASCII_LINELENGTH+1], *asp;
 
@@ -144,8 +144,8 @@ hex_and_ascii_print_with_offset(netdissect_options *ndo, register const char *id
 }
 
 void
-hex_and_ascii_print(netdissect_options *ndo, register const char *ident,
-    register const u_char *cp, register u_int length)
+hex_and_ascii_print(netdissect_options *ndo, const char *ident,
+    const u_char *cp, u_int length)
 {
        hex_and_ascii_print_with_offset(ndo, ident, cp, length, 0);
 }
@@ -159,8 +159,8 @@ hex_print_with_offset(netdissect_options *ndo,
                      u_int oset)
 {
        u_int caplength;
-       register u_int i, s;
-       register int nshorts;
+       u_int i, s;
+       int nshorts;
 
        caplength = (ndo->ndo_snapend >= cp) ? ndo->ndo_snapend - cp : 0;
        if (length > caplength)
index f8f95de4d5504d40294b6d42b4c233b6360f1b7e..462447d8cc558a70117d6c36bb5024c4d9a3cacc 100644 (file)
@@ -92,11 +92,11 @@ ltalk_if_print(netdissect_options *ndo,
  */
 u_int
 llap_print(netdissect_options *ndo,
-           register const u_char *bp, u_int length)
+           const u_char *bp, u_int length)
 {
-       register const struct LAP *lp;
-       register const struct atDDP *dp;
-       register const struct atShortDDP *sdp;
+       const struct LAP *lp;
+       const struct atDDP *dp;
+       const struct atShortDDP *sdp;
        u_short snet;
        u_int hdrlen;
 
@@ -177,9 +177,9 @@ llap_print(netdissect_options *ndo,
  */
 void
 atalk_print(netdissect_options *ndo,
-            register const u_char *bp, u_int length)
+            const u_char *bp, u_int length)
 {
-       register const struct atDDP *dp;
+       const struct atDDP *dp;
        u_short snet;
 
         if(!ndo->ndo_eflag)
@@ -208,9 +208,9 @@ atalk_print(netdissect_options *ndo,
 /* XXX should probably pass in the snap header and do checks like arp_print() */
 void
 aarp_print(netdissect_options *ndo,
-           register const u_char *bp, u_int length)
+           const u_char *bp, u_int length)
 {
-       register const struct aarp *ap;
+       const struct aarp *ap;
 
 #define AT(member) ataddr_string(ndo, (ap->member[1]<<8)|ap->member[2],ap->member[3])
 
@@ -252,8 +252,8 @@ aarp_print(netdissect_options *ndo,
  */
 static void
 ddp_print(netdissect_options *ndo,
-          register const u_char *bp, register u_int length, register int t,
-          register u_short snet, register u_char snode, u_char skt)
+          const u_char *bp, u_int length, int t,
+          u_short snet, u_char snode, u_char skt)
 {
 
        switch (t) {
@@ -278,7 +278,7 @@ ddp_print(netdissect_options *ndo,
 
 static void
 atp_print(netdissect_options *ndo,
-          register const struct atATP *ap, u_int length)
+          const struct atATP *ap, u_int length)
 {
        uint32_t data;
 
@@ -373,9 +373,9 @@ atp_print(netdissect_options *ndo,
 
 static void
 atp_bitmap_print(netdissect_options *ndo,
-                 register u_char bm)
+                 u_char bm)
 {
-       register int i;
+       int i;
 
        /*
         * The '& 0xff' below is needed for compilers that want to sign
@@ -383,7 +383,7 @@ atp_bitmap_print(netdissect_options *ndo,
         * (gcc is smart enough to eliminate it, at least on the Sparc).
         */
        if ((bm + 1) & (bm & 0xff)) {
-               register char c = '<';
+               char c = '<';
                for (i = 0; bm; ++i) {
                        if (bm & 1) {
                                ND_PRINT((ndo, "%c%d", c, i));
@@ -404,10 +404,10 @@ atp_bitmap_print(netdissect_options *ndo,
 
 static void
 nbp_print(netdissect_options *ndo,
-          register const struct atNBP *np, u_int length, register u_short snet,
-          register u_char snode, register u_char skt)
+          const struct atNBP *np, u_int length, u_short snet,
+          u_char snode, u_char skt)
 {
-       register const struct atNBPtuple *tp =
+       const struct atNBPtuple *tp =
                (const struct atNBPtuple *)((const u_char *)np + nbpHeaderSize);
        int i;
        const u_char *ep;
@@ -472,9 +472,9 @@ nbp_print(netdissect_options *ndo,
 /* print a counted string */
 static const char *
 print_cstring(netdissect_options *ndo,
-              register const char *cp, register const u_char *ep)
+              const char *cp, const u_char *ep)
 {
-       register u_int length;
+       u_int length;
 
        if (cp >= (const char *)ep) {
                ND_PRINT((ndo, "%s", tstr));
@@ -502,10 +502,10 @@ print_cstring(netdissect_options *ndo,
 
 static const struct atNBPtuple *
 nbp_tuple_print(netdissect_options *ndo,
-                register const struct atNBPtuple *tp, register const u_char *ep,
-                register u_short snet, register u_char snode, register u_char skt)
+                const struct atNBPtuple *tp, const u_char *ep,
+                u_short snet, u_char snode, u_char skt)
 {
-       register const struct atNBPtuple *tpn;
+       const struct atNBPtuple *tpn;
 
        if ((const u_char *)(tp + 1) > ep) {
                ND_PRINT((ndo, "%s", tstr));
@@ -531,9 +531,9 @@ nbp_tuple_print(netdissect_options *ndo,
 
 static const struct atNBPtuple *
 nbp_name_print(netdissect_options *ndo,
-               const struct atNBPtuple *tp, register const u_char *ep)
+               const struct atNBPtuple *tp, const u_char *ep)
 {
-       register const char *cp = (const char *)tp + nbpTupleSize;
+       const char *cp = (const char *)tp + nbpTupleSize;
 
        ND_PRINT((ndo, " "));
 
@@ -567,8 +567,8 @@ static const char *
 ataddr_string(netdissect_options *ndo,
               u_short atnet, u_char athost)
 {
-       register struct hnamemem *tp, *tp2;
-       register int i = (atnet << 8) | athost;
+       struct hnamemem *tp, *tp2;
+       int i = (atnet << 8) | athost;
        char nambuf[256+1];
        static int first = 1;
        FILE *fp;
@@ -649,7 +649,7 @@ static const struct tok skt2str[] = {
 
 static const char *
 ddpskt_string(netdissect_options *ndo,
-              register int skt)
+              int skt)
 {
        static char buf[8];
 
index 45ec2c5c074c1bf6ce8f0f423ff10b3b7bf0586f..e52fbf2b446e1580fddb0c14268e5adac95994b3 100644 (file)
@@ -178,7 +178,7 @@ static const struct tok bfd_v1_state_values[] = {
 };
 
 static int
-auth_print(netdissect_options *ndo, register const u_char *pptr)
+auth_print(netdissect_options *ndo, const u_char *pptr)
 {
         const struct bfd_auth_header_t *bfd_auth_header;
         int i;
@@ -289,8 +289,8 @@ trunc:
 }
 
 void
-bfd_print(netdissect_options *ndo, register const u_char *pptr,
-          register u_int len, register u_int port)
+bfd_print(netdissect_options *ndo, const u_char *pptr,
+          u_int len, u_int port)
 {
         const struct bfd_header_t *bfd_header;
         uint8_t version = 0;
index 8e225f850b82a5436c0f002fdd7bf5763074eeba..eb55fdb5b9ba81e83377dff60f14cfe16529a76a 100644 (file)
@@ -281,9 +281,9 @@ static const struct tok bootp_op_values[] = {
  */
 void
 bootp_print(netdissect_options *ndo,
-           register const u_char *cp, u_int length)
+           const u_char *cp, u_int length)
 {
-       register const struct bootp *bp;
+       const struct bootp *bp;
        static const u_char vm_cmu[4] = VM_CMU;
        static const u_char vm_rfc1048[4] = VM_RFC1048;
 
@@ -593,12 +593,12 @@ static const struct tok agent_suboption_values[] = {
 
 static void
 rfc1048_print(netdissect_options *ndo,
-             register const u_char *bp)
+             const u_char *bp)
 {
-       register uint16_t tag;
-       register u_int len;
-       register const char *cp;
-       register char c;
+       uint16_t tag;
+       u_int len;
+       const char *cp;
+       char c;
        int first, idx;
        uint32_t ul;
        uint16_t us;
@@ -1060,9 +1060,9 @@ trunc:
 
 static void
 cmu_print(netdissect_options *ndo,
-         register const u_char *bp)
+         const u_char *bp)
 {
-       register const struct cmu_vend *cmu;
+       const struct cmu_vend *cmu;
 
 #define PRINTCMUADDR(m, s) { ND_TCHECK(cmu->m); \
     if (cmu->m.s_addr != 0) \
index 589815544565d7f22c25b9a4a4e36c6c61b1080f..807e977f0ee53d7b1d30ebe8e1f5dcb46aee1765 100644 (file)
@@ -46,7 +46,7 @@
 #include "extract.h"
 
 void
-carp_print(netdissect_options *ndo, register const u_char *bp, register u_int len, int ttl)
+carp_print(netdissect_options *ndo, const u_char *bp, u_int len, int ttl)
 {
        int version, type;
        const char *type_s;
index 0a666478a47e15d4701863b26ef9d609d03d9253..bc5125f17580ab8493384367e560be18bfb05bc7 100644 (file)
@@ -216,7 +216,7 @@ static const struct tok cfm_tlv_senderid_chassisid_values[] = {
 
 static int
 cfm_network_addr_print(netdissect_options *ndo,
-                       register const u_char *tptr, const u_int length)
+                       const u_char *tptr, const u_int length)
 {
     u_int network_addr_type;
     u_int hexdump =  FALSE;
@@ -268,7 +268,7 @@ cfm_network_addr_print(netdissect_options *ndo,
 
 void
 cfm_print(netdissect_options *ndo,
-          register const u_char *pptr, register u_int length)
+          const u_char *pptr, u_int length)
 {
     const struct cfm_common_header_t *cfm_common_header;
     const struct cfm_tlv_header_t *cfm_tlv_header;
index 1c6fe36b0f41c02cafbfba485244c0bdaa510933..9893f7732b5f9ddf1e04a2844f29f194f107218c 100644 (file)
@@ -45,13 +45,13 @@ static const struct tok chdlc_cast_values[] = {
 
 /* Standard CHDLC printer */
 u_int
-chdlc_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, register const u_char *p)
+chdlc_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p)
 {
        return chdlc_print(ndo, p, h->len);
 }
 
 u_int
-chdlc_print(netdissect_options *ndo, register const u_char *p, u_int length)
+chdlc_print(netdissect_options *ndo, const u_char *p, u_int length)
 {
        u_int proto;
        const u_char *bp = p;
index 162b1f9f149fcb9a869ae7d63ecf6f8054a76ecd..e9e9e6db04035c9d824bc09c79b2a5b3e7db9bd7 100644 (file)
@@ -157,8 +157,8 @@ struct nfrec_v6 {
 static void
 cnfp_v1_print(netdissect_options *ndo, const u_char *cp)
 {
-       register const struct nfhdr_v1 *nh;
-       register const struct nfrec_v1 *nr;
+       const struct nfhdr_v1 *nh;
+       const struct nfrec_v1 *nr;
        const char *p_name;
        int nrecs, ver;
 #if 0
@@ -246,8 +246,8 @@ trunc:
 static void
 cnfp_v5_print(netdissect_options *ndo, const u_char *cp)
 {
-       register const struct nfhdr_v5 *nh;
-       register const struct nfrec_v5 *nr;
+       const struct nfhdr_v5 *nh;
+       const struct nfrec_v5 *nr;
        const char *p_name;
        int nrecs, ver;
 #if 0
@@ -342,8 +342,8 @@ trunc:
 static void
 cnfp_v6_print(netdissect_options *ndo, const u_char *cp)
 {
-       register const struct nfhdr_v6 *nh;
-       register const struct nfrec_v6 *nr;
+       const struct nfhdr_v6 *nh;
+       const struct nfrec_v6 *nr;
        const char *p_name;
        int nrecs, ver;
 #if 0
index 51070119915cbc02e3b38a8e4e894b69fbfd38b8..b86bd8896794442c1c42b708307019b7e5726462 100644 (file)
@@ -498,11 +498,11 @@ extern char *dnet_htoa(struct dn_naddr *);
 
 void
 decnet_print(netdissect_options *ndo,
-             register const u_char *ap, register u_int length,
-             register u_int caplen)
+             const u_char *ap, u_int length,
+             u_int caplen)
 {
-       register const union routehdr *rhp;
-       register int mflags;
+       const union routehdr *rhp;
+       int mflags;
        int dst, src, hops;
        u_int nsplen, pktlen;
        const u_char *nspp;
@@ -611,12 +611,12 @@ trunc:
 
 static int
 print_decnet_ctlmsg(netdissect_options *ndo,
-                    register const union routehdr *rhp, u_int length,
+                    const union routehdr *rhp, u_int length,
                     u_int caplen)
 {
        /* Our caller has already checked for mflags */
        int mflags = EXTRACT_U_1(rhp->rh_short.sh_flags);
-       register const union controlmsg *cmp = (const union controlmsg *)rhp;
+       const union controlmsg *cmp = (const union controlmsg *)rhp;
        int src, dst, info, blksize, eco, ueco, hello, other, vers;
        etheraddr srcea, rtea;
        int priority;
@@ -1233,7 +1233,7 @@ static const struct tok reason2str[] = {
 
 static void
 print_reason(netdissect_options *ndo,
-             register int reason)
+             int reason)
 {
        ND_PRINT((ndo, "%s ", tok2str(reason2str, "reason-%d", reason)));
 }
index 303dc28c6f207ebe19fa2029a86faaf46ba9f998..ea80aeba1ed9501db69b4534cd5718a764c17d01 100644 (file)
@@ -52,9 +52,9 @@ static const char *ns_resp[] = {
 /* skip over a domain name */
 static const u_char *
 ns_nskip(netdissect_options *ndo,
-         register const u_char *cp)
+         const u_char *cp)
 {
-       register u_char i;
+       u_char i;
 
        if (!ND_TTEST_1(cp))
                return (NULL);
@@ -129,7 +129,7 @@ static int
 labellen(netdissect_options *ndo,
          const u_char *cp)
 {
-       register u_int i;
+       u_int i;
 
        if (!ND_TTEST_1(cp))
                return(-1);
@@ -151,11 +151,11 @@ labellen(netdissect_options *ndo,
 
 const u_char *
 ns_nprint(netdissect_options *ndo,
-          register const u_char *cp, register const u_char *bp)
+          const u_char *cp, const u_char *bp)
 {
-       register u_int i, l;
-       register const u_char *rp = NULL;
-       register int compress = 0;
+       u_int i, l;
+       const u_char *rp = NULL;
+       int compress = 0;
        int elt;
        u_int offset, max_offset;
 
@@ -241,9 +241,9 @@ ns_nprint(netdissect_options *ndo,
 /* print a <character-string> */
 static const u_char *
 ns_cprint(netdissect_options *ndo,
-          register const u_char *cp)
+          const u_char *cp)
 {
-       register u_int i;
+       u_int i;
 
        if (!ND_TTEST_1(cp))
                return (NULL);
@@ -331,10 +331,10 @@ const struct tok ns_class2str[] = {
 /* print a query */
 static const u_char *
 ns_qprint(netdissect_options *ndo,
-          register const u_char *cp, register const u_char *bp, int is_mdns)
+          const u_char *cp, const u_char *bp, int is_mdns)
 {
-       register const u_char *np = cp;
-       register u_int i, class;
+       const u_char *np = cp;
+       u_int i, class;
 
        cp = ns_nskip(ndo, cp);
 
@@ -366,11 +366,11 @@ ns_qprint(netdissect_options *ndo,
 /* print a reply */
 static const u_char *
 ns_rprint(netdissect_options *ndo,
-          register const u_char *cp, register const u_char *bp, int is_mdns)
+          const u_char *cp, const u_char *bp, int is_mdns)
 {
-       register u_int i, class, opt_flags = 0;
-       register u_short typ, len;
-       register const u_char *rp;
+       u_int i, class, opt_flags = 0;
+       u_short typ, len;
+       const u_char *rp;
 
        if (ndo->ndo_vflag) {
                ND_PRINT((ndo, " "));
@@ -585,13 +585,13 @@ ns_rprint(netdissect_options *ndo,
 
 void
 domain_print(netdissect_options *ndo,
-         register const u_char *bp, u_int length, int is_mdns)
+         const u_char *bp, u_int length, int is_mdns)
 {
-       register const HEADER *np;
+       const HEADER *np;
        u_int16_t flags;
        u_int qdcount, ancount, nscount, arcount;
        u_int i;
-       register const u_char *cp;
+       const u_char *cp;
        uint16_t b2;
 
        np = (const HEADER *)bp;
index cfc3f710080ebba064fec69efd001c8a77c6c498..91daec833ecc064b14e6f03f7d28c55f3b1b2ba3 100644 (file)
@@ -67,10 +67,10 @@ static int print_graft_ack(netdissect_options *, const u_char *);
 
 void
 dvmrp_print(netdissect_options *ndo,
-            register const u_char *bp, register u_int len)
+            const u_char *bp, u_int len)
 {
-       register const u_char *ep;
-       register u_char type;
+       const u_char *ep;
+       u_char type;
        uint8_t major_version, minor_version;
 
        ep = (const u_char *)ndo->ndo_snapend;
@@ -162,12 +162,12 @@ trunc:
 
 static int
 print_report(netdissect_options *ndo,
-             register const u_char *bp, register const u_char *ep,
-             register u_int len)
+             const u_char *bp, const u_char *ep,
+             u_int len)
 {
-       register uint32_t mask, origin;
-       register int metric, done;
-       register u_int i, width;
+       uint32_t mask, origin;
+       int metric, done;
+       u_int i, width;
 
        while (len > 0) {
                if (len < 3) {
@@ -223,10 +223,10 @@ trunc:
 
 static int
 print_probe(netdissect_options *ndo,
-            register const u_char *bp, register const u_char *ep,
-            register u_int len)
+            const u_char *bp, const u_char *ep,
+            u_int len)
 {
-       register uint32_t genid;
+       uint32_t genid;
 
        ND_TCHECK_4(bp);
        if ((len < 4) || ((bp + 4) > ep)) {
@@ -255,13 +255,13 @@ trunc:
 
 static int
 print_neighbors(netdissect_options *ndo,
-                register const u_char *bp, register const u_char *ep,
-                register u_int len)
+                const u_char *bp, const u_char *ep,
+                u_int len)
 {
        const u_char *laddr;
-       register u_char metric;
-       register u_char thresh;
-       register int ncount;
+       u_char metric;
+       u_char thresh;
+       int ncount;
 
        while (len > 0 && bp < ep) {
                ND_TCHECK_7(bp);
@@ -290,13 +290,13 @@ trunc:
 
 static int
 print_neighbors2(netdissect_options *ndo,
-                 register const u_char *bp, register const u_char *ep,
-                 register u_int len, uint8_t major_version,
+                 const u_char *bp, const u_char *ep,
+                 u_int len, uint8_t major_version,
                  uint8_t minor_version)
 {
        const u_char *laddr;
-       register u_char metric, thresh, flags;
-       register int ncount;
+       u_char metric, thresh, flags;
+       int ncount;
 
        ND_PRINT((ndo, " (v %u.%u):", major_version, minor_version));
 
@@ -343,7 +343,7 @@ trunc:
 
 static int
 print_prune(netdissect_options *ndo,
-            register const u_char *bp)
+            const u_char *bp)
 {
        ND_TCHECK_LEN(bp, 12);
        ND_PRINT((ndo, " src %s grp %s", ipaddr_string(ndo, bp), ipaddr_string(ndo, bp + 4)));
@@ -357,7 +357,7 @@ trunc:
 
 static int
 print_graft(netdissect_options *ndo,
-            register const u_char *bp)
+            const u_char *bp)
 {
        ND_TCHECK_8(bp);
        ND_PRINT((ndo, " src %s grp %s", ipaddr_string(ndo, bp), ipaddr_string(ndo, bp + 4)));
@@ -368,7 +368,7 @@ trunc:
 
 static int
 print_graft_ack(netdissect_options *ndo,
-                register const u_char *bp)
+                const u_char *bp)
 {
        ND_TCHECK_8(bp);
        ND_PRINT((ndo, " src %s grp %s", ipaddr_string(ndo, bp), ipaddr_string(ndo, bp + 4)));
index 95eaa17ad5e17e3a1256c8f5becb34e3cabe2892..827bf6725b0a185bb6934140af31c89f2e0674c8 100644 (file)
@@ -148,7 +148,7 @@ static const struct tok eap_aka_subtype_values[] = {
  */
 void
 eap_print(netdissect_options *ndo,
-          register const u_char *cp,
+          const u_char *cp,
           u_int length)
 {
     const struct eap_frame_t *eap;
index 7bcf16cfeded3bd6aa63a644e3422429dc4a9691..b5306d02901b2ee45420d40c82386bf6391cf5f7 100644 (file)
@@ -129,12 +129,12 @@ static const char *egp_reasons[] = {
 
 static void
 egpnrprint(netdissect_options *ndo,
-           register const struct egp_packet *egp, u_int length)
+           const struct egp_packet *egp, u_int length)
 {
-       register const uint8_t *cp;
+       const uint8_t *cp;
        uint32_t addr;
-       register uint32_t net;
-       register u_int netlen;
+       uint32_t net;
+       u_int netlen;
        u_int gateways, distances, networks;
        u_int t_gateways;
        const char *comma;
@@ -241,12 +241,12 @@ trunc:
 
 void
 egp_print(netdissect_options *ndo,
-          register const uint8_t *bp, register u_int length)
+          const uint8_t *bp, u_int length)
 {
-       register const struct egp_packet *egp;
-       register int status;
-       register int code;
-       register int type;
+       const struct egp_packet *egp;
+       int status;
+       int code;
+       int type;
 
        egp = (const struct egp_packet *)bp;
        if (length < sizeof(*egp) || !ND_TTEST(*egp)) {
index 2a13915146bd4e1a033593316cd160a9c1e80f9e..95a00ef6ba656fe2aa28a658c658911a7cb6ec0b 100644 (file)
@@ -207,7 +207,7 @@ static const struct tok eigrp_ext_proto_id_values[] = {
 };
 
 void
-eigrp_print(netdissect_options *ndo, register const u_char *pptr, register u_int len)
+eigrp_print(netdissect_options *ndo, const u_char *pptr, u_int len)
 {
     const struct eigrp_common_header *eigrp_com_header;
     const struct eigrp_tlv_header *eigrp_tlv_header;
index 4a43a491b681832877939a989d2afd9cbef71f56..c3fcf10c7da0d287c590282092b09bfbe82ad464 100644 (file)
@@ -87,10 +87,10 @@ struct enchdr {
 
 u_int
 enc_if_print(netdissect_options *ndo,
-             const struct pcap_pkthdr *h, register const u_char *p)
+             const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
        int flags;
        const struct enchdr *hdr;
 
index d71bd23e1be8066526bbd69f6f7c963e695ddb5c..ade700a29540faa7debdd026856b213b85ad29aa 100644 (file)
@@ -647,8 +647,8 @@ esp_print(netdissect_options *ndo,
 #endif
        )
 {
-       register const struct newesp *esp;
-       register const u_char *ep;
+       const struct newesp *esp;
+       const u_char *ep;
 #ifdef HAVE_LIBCRYPTO
        const struct ip *ip;
        struct sa_list *sa = NULL;
index 7e7216c4cd1e7cb0213e4454bf4b1d8f658ef5b2..ce96e62ec214a3df9d9b56763467ca67e4c5f062 100644 (file)
@@ -108,7 +108,7 @@ static inline void
 ether_hdr_print(netdissect_options *ndo,
                 const u_char *bp, u_int length)
 {
-       register const struct ether_header *ep;
+       const struct ether_header *ep;
        uint16_t length_type;
 
        ep = (const struct ether_header *)bp;
index 01f376f823c71204a0f93b6cc8732decc3b73524..0b85034a6d922590493272764b4d9d26f6ec23de 100644 (file)
@@ -229,7 +229,7 @@ print_fddi_fc(netdissect_options *ndo, u_char fc)
 static inline void
 extract_fddi_addrs(const struct fddi_header *fddip, char *fsrc, char *fdst)
 {
-       register int i;
+       int i;
 
        if (fddi_bitswap) {
                /*
@@ -252,8 +252,8 @@ extract_fddi_addrs(const struct fddi_header *fddip, char *fsrc, char *fdst)
  */
 static inline void
 fddi_hdr_print(netdissect_options *ndo,
-               register const struct fddi_header *fddip, register u_int length,
-               register const u_char *fsrc, register const u_char *fdst)
+               const struct fddi_header *fddip, u_int length,
+               const u_char *fsrc, const u_char *fdst)
 {
        const char *srcname, *dstname;
 
@@ -342,7 +342,7 @@ fddi_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen)
  * is the number of bytes actually captured.
  */
 u_int
-fddi_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, register const u_char *p)
+fddi_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p)
 {
        return (fddi_print(ndo, p, h->len, h->caplen));
 }
index 5209990e9be4345a930cf68c1be44ca405779485..f6be80c21243b5af6322edc1996551705e865ab5 100644 (file)
@@ -66,7 +66,7 @@ struct tom_h {
        uint16_t flags;
        uint16_t op_msk;
        const char *s;
-       int (*print) (netdissect_options *ndo, register const u_char * pptr, register u_int len,
+       int (*print) (netdissect_options *ndo, const u_char * pptr, u_int len,
                      uint16_t op_msk, int indent);
 };
 
@@ -230,15 +230,15 @@ struct optlv_h {
        uint16_t flags;
        uint16_t op_msk;
        const char *s;
-       int (*print) (netdissect_options *ndo, register const u_char * pptr, register u_int len,
+       int (*print) (netdissect_options *ndo, const u_char * pptr, u_int len,
                      uint16_t op_msk, int indent);
 };
 
-static int genoptlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int genoptlv_print(netdissect_options *, const u_char * pptr, u_int len,
                         uint16_t op_msk, int indent);
-static int recpdoptlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int recpdoptlv_print(netdissect_options *, const u_char * pptr, u_int len,
                            uint16_t op_msk, int indent);
-static int invoptlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int invoptlv_print(netdissect_options *, const u_char * pptr, u_int len,
                          uint16_t op_msk, int indent);
 
 #define OP_MIN_SIZ 8
@@ -440,13 +440,13 @@ static inline int ilv_valid(const struct forces_ilv *ilv, u_int rlen)
        return 0;
 }
 
-static int lfbselect_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int lfbselect_print(netdissect_options *, const u_char * pptr, u_int len,
                           uint16_t op_msk, int indent);
-static int redirect_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int redirect_print(netdissect_options *, const u_char * pptr, u_int len,
                          uint16_t op_msk, int indent);
-static int asrtlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int asrtlv_print(netdissect_options *, const u_char * pptr, u_int len,
                        uint16_t op_msk, int indent);
-static int asttlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int asttlv_print(netdissect_options *, const u_char * pptr, u_int len,
                        uint16_t op_msk, int indent);
 
 struct forces_lfbsh {
@@ -498,7 +498,7 @@ struct pdata_ops {
        uint16_t flags;
        uint16_t op_msk;
        const char *s;
-       int (*print) (netdissect_options *, register const u_char * pptr, register u_int len,
+       int (*print) (netdissect_options *, const u_char * pptr, u_int len,
                      uint16_t op_msk, int indent);
 };
 
@@ -549,13 +549,13 @@ struct res_val {
        nd_uint16_t resv2;
 };
 
-static int prestlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int prestlv_print(netdissect_options *, const u_char * pptr, u_int len,
                         uint16_t op_msk, int indent);
-static int pkeyitlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int pkeyitlv_print(netdissect_options *, const u_char * pptr, u_int len,
                          uint16_t op_msk, int indent);
-static int fdatatlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int fdatatlv_print(netdissect_options *, const u_char * pptr, u_int len,
                          uint16_t op_msk, int indent);
-static int sdatatlv_print(netdissect_options *, register const u_char * pptr, register u_int len,
+static int sdatatlv_print(netdissect_options *, const u_char * pptr, u_int len,
                          uint16_t op_msk, int indent);
 
 static const struct pdata_ops ForCES_pdata[PD_MAX_IND + 1] = {
@@ -641,11 +641,11 @@ static const struct tok ForCES_errs[] = {
 
 static int
 prestlv_print(netdissect_options *ndo,
-              register const u_char * pptr, register u_int len,
+              const u_char * pptr, u_int len,
               uint16_t op_msk _U_, int indent)
 {
        const struct forces_tlv *tlv = (const struct forces_tlv *)pptr;
-       register const u_char *tdp = (const u_char *) TLV_DATA(tlv);
+       const u_char *tdp = (const u_char *) TLV_DATA(tlv);
        const struct res_val *r = (const struct res_val *)tdp;
        u_int dlen;
        uint8_t result;
@@ -681,12 +681,12 @@ trunc:
 
 static int
 fdatatlv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk _U_, int indent)
 {
        const struct forces_tlv *tlv = (const struct forces_tlv *)pptr;
        u_int rlen;
-       register const u_char *tdp = (const u_char *) TLV_DATA(tlv);
+       const u_char *tdp = (const u_char *) TLV_DATA(tlv);
        uint16_t type;
 
        /*
@@ -716,7 +716,7 @@ trunc:
 
 static int
 sdatailv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk _U_, int indent)
 {
        u_int rlen;
@@ -734,7 +734,7 @@ sdatailv_print(netdissect_options *ndo,
                ND_PRINT((ndo, "Jamal - outstanding length <%d>\n", rlen));
 #endif
                char *ib = indent_pr(indent, 1);
-               register const u_char *tdp = (const u_char *) ILV_DATA(ilv);
+               const u_char *tdp = (const u_char *) ILV_DATA(ilv);
                ND_TCHECK(*ilv);
                invilv = ilv_valid(ilv, rlen);
                if (invilv) {
@@ -762,12 +762,12 @@ trunc:
 
 static int
 sdatatlv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk, int indent)
 {
        const struct forces_tlv *tlv = (const struct forces_tlv *)pptr;
        u_int rlen;
-       register const u_char *tdp = (const u_char *) TLV_DATA(tlv);
+       const u_char *tdp = (const u_char *) TLV_DATA(tlv);
        uint16_t type;
 
        /*
@@ -791,12 +791,12 @@ trunc:
 
 static int
 pkeyitlv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk, int indent)
 {
        const struct forces_tlv *tlv = (const struct forces_tlv *)pptr;
-       register const u_char *tdp = (const u_char *) TLV_DATA(tlv);
-       register const u_char *dp = tdp + 4;
+       const u_char *tdp = (const u_char *) TLV_DATA(tlv);
+       const u_char *dp = tdp + 4;
        const struct forces_tlv *kdtlv = (const struct forces_tlv *)dp;
        uint32_t id;
        char *ib = indent_pr(indent, 0);
@@ -834,7 +834,7 @@ trunc:
 
 static int
 pdatacnt_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t IDcnt, uint16_t op_msk, int indent)
 {
        u_int i;
@@ -989,7 +989,7 @@ trunc:
 
 static int
 pdata_print(netdissect_options *ndo,
-            register const u_char * pptr, register u_int len,
+            const u_char * pptr, u_int len,
             uint16_t op_msk, int indent)
 {
        const struct pathdata_h *pdh = (const struct pathdata_h *)pptr;
@@ -1053,7 +1053,7 @@ trunc:
 
 static int
 genoptlv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk, int indent)
 {
        const struct forces_tlv *pdtlv = (const struct forces_tlv *)pptr;
@@ -1074,7 +1074,7 @@ genoptlv_print(netdissect_options *ndo,
                 * length is large enough but not too large (it doesn't
                 * go past the end of the containing TLV).
                 */
-               register const u_char *dp = (const u_char *) TLV_DATA(pdtlv);
+               const u_char *dp = (const u_char *) TLV_DATA(pdtlv);
                if (!ttlv_valid(type)) {
                        ND_PRINT((ndo, "%s TLV type 0x%x len %d\n",
                               tok2str(ForCES_TLV_err, NULL, invtlv), type,
@@ -1099,14 +1099,14 @@ trunc:
 
 static int
 recpdoptlv_print(netdissect_options *ndo,
-                 register const u_char * pptr, register u_int len,
+                 const u_char * pptr, u_int len,
                  uint16_t op_msk, int indent)
 {
        const struct forces_tlv *pdtlv = (const struct forces_tlv *)pptr;
        int tll;
        u_int invtlv;
        uint16_t type;
-       register const u_char *dp;
+       const u_char *dp;
        char *ib;
 
        while (len != 0) {
@@ -1153,7 +1153,7 @@ trunc:
 
 static int
 invoptlv_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk _U_, int indent)
 {
        char *ib = indent_pr(indent, 1);
@@ -1171,7 +1171,7 @@ otlv_print(netdissect_options *ndo,
            const struct forces_tlv *otlv, uint16_t op_msk _U_, int indent)
 {
        int rc = 0;
-       register const u_char *dp = (const u_char *) TLV_DATA(otlv);
+       const u_char *dp = (const u_char *) TLV_DATA(otlv);
        uint16_t type;
        int tll;
        char *ib = indent_pr(indent, 0);
@@ -1214,7 +1214,7 @@ trunc:
 #define ASTMCD 255
 static int
 asttlv_print(netdissect_options *ndo,
-             register const u_char * pptr, register u_int len,
+             const u_char * pptr, u_int len,
              uint16_t op_msk _U_, int indent)
 {
        uint32_t rescode;
@@ -1272,7 +1272,7 @@ trunc:
 #define ASRMCD 3
 static int
 asrtlv_print(netdissect_options *ndo,
-             register const u_char * pptr, register u_int len,
+             const u_char * pptr, u_int len,
              uint16_t op_msk _U_, int indent)
 {
        uint32_t rescode;
@@ -1327,7 +1327,7 @@ trunc:
  */
 static int
 gentltlv_print(netdissect_options *ndo,
-               register const u_char * pptr _U_, register u_int len,
+               const u_char * pptr _U_, u_int len,
                uint16_t op_msk _U_, int indent _U_)
 {
        u_int dlen = len - TLV_HDRL;
@@ -1344,7 +1344,7 @@ gentltlv_print(netdissect_options *ndo,
 
 static int
 print_metailv(netdissect_options *ndo,
-              register const u_char * pptr, uint16_t op_msk _U_, int indent)
+              const u_char * pptr, uint16_t op_msk _U_, int indent)
 {
        u_int rlen;
        char *ib = indent_pr(indent, 0);
@@ -1372,7 +1372,7 @@ trunc:
 
 static int
 print_metatlv(netdissect_options *ndo,
-              register const u_char * pptr, register u_int len,
+              const u_char * pptr, u_int len,
               uint16_t op_msk _U_, int indent)
 {
        u_int dlen;
@@ -1414,7 +1414,7 @@ trunc:
 
 static int
 print_reddata(netdissect_options *ndo,
-              register const u_char * pptr, register u_int len,
+              const u_char * pptr, u_int len,
               uint16_t op_msk _U_, int indent)
 {
        u_int dlen;
@@ -1436,7 +1436,7 @@ print_reddata(netdissect_options *ndo,
 
 static int
 redirect_print(netdissect_options *ndo,
-               register const u_char * pptr, register u_int len,
+               const u_char * pptr, u_int len,
                uint16_t op_msk _U_, int indent)
 {
        const struct forces_tlv *tlv = (const struct forces_tlv *)pptr;
@@ -1507,7 +1507,7 @@ trunc:
 
 static int
 lfbselect_print(netdissect_options *ndo,
-                register const u_char * pptr, register u_int len,
+                const u_char * pptr, u_int len,
                 uint16_t op_msk, int indent)
 {
        const struct forces_lfbsh *lfbs;
@@ -1586,8 +1586,8 @@ trunc:
 
 static int
 forces_type_print(netdissect_options *ndo,
-                  register const u_char * pptr, const struct forcesh *fhdr _U_,
-                  register u_int mlen, const struct tom_h *tops)
+                  const u_char * pptr, const struct forcesh *fhdr _U_,
+                  u_int mlen, const struct tom_h *tops)
 {
        const struct forces_tlv *tltlv;
        u_int rlen;
@@ -1677,7 +1677,7 @@ trunc:
 
 void
 forces_print(netdissect_options *ndo,
-             register const u_char * pptr, register u_int len)
+             const u_char * pptr, u_int len)
 {
        const struct forcesh *fhdr;
        u_int mlen;
index c5d5e5d73153a60f38fc192d154f238ac28e3c60..0d34c03912739f7bbf83e36cae2156b90a500c96 100644 (file)
@@ -217,10 +217,10 @@ fr_hdr_print(netdissect_options *ndo,
 
 u_int
 fr_if_print(netdissect_options *ndo,
-            const struct pcap_pkthdr *h, register const u_char *p)
+            const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
 
         ND_TCHECK_4(p); /* minimum frame header length */
 
@@ -235,7 +235,7 @@ fr_if_print(netdissect_options *ndo,
 
 u_int
 fr_print(netdissect_options *ndo,
-         register const u_char *p, u_int length)
+         const u_char *p, u_int length)
 {
        int ret;
        uint16_t extracted_ethertype;
@@ -373,10 +373,10 @@ fr_print(netdissect_options *ndo,
 
 u_int
 mfr_if_print(netdissect_options *ndo,
-             const struct pcap_pkthdr *h, register const u_char *p)
+             const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
 
         ND_TCHECK_2(p); /* minimum frame header length */
 
@@ -435,7 +435,7 @@ struct ie_tlv_header_t {
 
 u_int
 mfr_print(netdissect_options *ndo,
-          register const u_char *p, u_int length)
+          const u_char *p, u_int length)
 {
     u_int tlen,idx,hdr_len = 0;
     uint16_t sequence_num;
index fe8f3cf774b47600ff1088cb28bebca81d7ddd71..f1728f0c530f51693a62f13baf160d2e5ae5e82c 100644 (file)
 #include "ip6.h"
 
 int
-frag6_print(netdissect_options *ndo, register const u_char *bp, register const u_char *bp2)
+frag6_print(netdissect_options *ndo, const u_char *bp, const u_char *bp2)
 {
-       register const struct ip6_frag *dp;
-       register const struct ip6_hdr *ip6;
+       const struct ip6_frag *dp;
+       const struct ip6_hdr *ip6;
 
        dp = (const struct ip6_frag *)bp;
        ip6 = (const struct ip6_hdr *)bp2;
index 35146460c8552d06344069b03a354c3f1f54c9be..a6ad21b6906b9a7d348f6679c88a92ef7d2d5a44 100644 (file)
@@ -93,7 +93,7 @@ struct hsrp {
 };
 
 void
-hsrp_print(netdissect_options *ndo, register const uint8_t *bp, register u_int len)
+hsrp_print(netdissect_options *ndo, const uint8_t *bp, u_int len)
 {
        const struct hsrp *hp = (const struct hsrp *) bp;
 
index ff65a854a0a40f5652e8dc07cef42cefb04891ca..4ebd977b7a4a0751051e6aa8fec3aa1f97f00299 100644 (file)
@@ -411,7 +411,7 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char *
 
                case ICMP_UNREACH_NEEDFRAG:
                    {
-                       register const struct mtu_discovery *mp;
+                       const struct mtu_discovery *mp;
                        mp = (const struct mtu_discovery *)(const u_char *)&dp->icmp_void;
                        mtu = EXTRACT_BE_U_2(&mp->nexthopmtu);
                        if (mtu) {
@@ -446,8 +446,8 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char *
 
        case ICMP_ROUTERADVERT:
            {
-               register const struct ih_rdiscovery *ihp;
-               register const struct id_rdiscovery *idp;
+               const struct ih_rdiscovery *ihp;
+               const struct id_rdiscovery *idp;
                u_int lifetime, num, size;
 
                (void)snprintf(buf, sizeof(buf), "router advertisement");
index 2fd9d1b4e5940a0d944fdc114f67ccc5f0b4130e..b2230f60b7aaaa464ef23994bed0891912b997fe 100644 (file)
@@ -1473,7 +1473,7 @@ mldv2_query_print(netdissect_options *ndo, const u_char *bp, u_int len)
     u_int mrc;
     int mrt, qqi;
     u_int nsrcs;
-    register u_int i;
+    u_int i;
 
     /* Minimum len is 28 */
     if (len < 28) {
index d0dfd3294785a6d2f63a088df36eaa377f5fb9d8..d5356dd229f56de35c62d233cc2a9af3750fae0e 100644 (file)
@@ -110,9 +110,9 @@ static const struct tok igmpv3report2str[] = {
 
 static void
 print_mtrace(netdissect_options *ndo,
-             register const u_char *bp, register u_int len)
+             const u_char *bp, u_int len)
 {
-    register const struct tr_query *tr = (const struct tr_query *)(bp + 8);
+    const struct tr_query *tr = (const struct tr_query *)(bp + 8);
 
     ND_TCHECK(*tr);
     if (len < 8 + sizeof (struct tr_query)) {
@@ -132,9 +132,9 @@ trunc:
 
 static void
 print_mresp(netdissect_options *ndo,
-            register const u_char *bp, register u_int len)
+            const u_char *bp, u_int len)
 {
-    register const struct tr_query *tr = (const struct tr_query *)(bp + 8);
+    const struct tr_query *tr = (const struct tr_query *)(bp + 8);
 
     ND_TCHECK(*tr);
     if (len < 8 + sizeof (struct tr_query)) {
@@ -154,10 +154,10 @@ trunc:
 
 static void
 print_igmpv3_report(netdissect_options *ndo,
-                    register const u_char *bp, register u_int len)
+                    const u_char *bp, u_int len)
 {
     u_int group, nsrcs, ngroups;
-    register u_int i, j;
+    u_int i, j;
 
     /* Minimum len is 16, and should be a multiple of 4 */
     if (len < 16 || len & 0x03) {
@@ -208,12 +208,12 @@ trunc:
 
 static void
 print_igmpv3_query(netdissect_options *ndo,
-                   register const u_char *bp, register u_int len)
+                   const u_char *bp, u_int len)
 {
     u_int mrc;
     u_int mrt;
     u_int nsrcs;
-    register u_int i;
+    u_int i;
 
     ND_PRINT((ndo, " v3"));
     /* Minimum len is 12, and should be a multiple of 4 */
@@ -264,7 +264,7 @@ trunc:
 
 void
 igmp_print(netdissect_options *ndo,
-           register const u_char *bp, register u_int len)
+           const u_char *bp, u_int len)
 {
     struct cksum_vec vec[1];
 
index 10915f882149d6e9f541aeb1e88555ce36c9f8f7..57df70f9efb4ae3f0a4a60e06ef3095a094cc962 100644 (file)
@@ -66,10 +66,10 @@ struct igrprte {
 #define IGRP_RTE_SIZE  14      /* don't believe sizeof ! */
 
 static void
-igrp_entry_print(netdissect_options *ndo, register const struct igrprte *igr,
-    register int is_interior, register int is_exterior)
+igrp_entry_print(netdissect_options *ndo, const struct igrprte *igr,
+    int is_interior, int is_exterior)
 {
-       register u_int delay, bandwidth;
+       u_int delay, bandwidth;
        u_int metric, mtu;
 
        if (is_interior)
@@ -102,10 +102,10 @@ static const struct tok op2str[] = {
 };
 
 void
-igrp_print(netdissect_options *ndo, register const u_char *bp, u_int length)
+igrp_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
-       register const struct igrphdr *hdr;
-       register const u_char *cp;
+       const struct igrphdr *hdr;
+       const u_char *cp;
        u_int nint, nsys, next;
 
        hdr = (const struct igrphdr *)bp;
index f2d1edbaaa5505e98ada4b55ab00e29a65707455..d24f46cc741c917a2f3d7f7c824cccd53c7a2bfa 100644 (file)
@@ -56,10 +56,10 @@ static const struct tok ip_option_values[] = {
  */
 static int
 ip_printroute(netdissect_options *ndo,
-              register const u_char *cp, u_int length)
+              const u_char *cp, u_int length)
 {
-       register u_int ptr;
-       register u_int len;
+       u_int ptr;
+       u_int len;
 
        if (length < 3) {
                ND_PRINT((ndo, " [bad length %u]", length));
@@ -170,10 +170,10 @@ nextproto4_cksum(netdissect_options *ndo,
 
 static int
 ip_printts(netdissect_options *ndo,
-           register const u_char *cp, u_int length)
+           const u_char *cp, u_int length)
 {
-       register u_int ptr;
-       register u_int len;
+       u_int ptr;
+       u_int len;
        int hoplen;
        const char *type;
 
@@ -244,9 +244,9 @@ trunc:
  */
 static void
 ip_optprint(netdissect_options *ndo,
-            register const u_char *cp, u_int length)
+            const u_char *cp, u_int length)
 {
-       register u_int option_len;
+       u_int option_len;
        const char *sep = "";
 
        for (; length > 0; cp += option_len, length -= option_len) {
@@ -706,7 +706,7 @@ trunc:
 }
 
 void
-ipN_print(netdissect_options *ndo, register const u_char *bp, register u_int length)
+ipN_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
        if (length < 1) {
                ND_PRINT((ndo, "truncated-ip %d", length));
index 3b63639e865cc3edf240bca7a3bfa5aa25ce8008..72297aae260004e902f46bd64f1c56a0ae652ed4 100644 (file)
@@ -215,12 +215,12 @@ nextproto6_cksum(netdissect_options *ndo,
 void
 ip6_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
-       register const struct ip6_hdr *ip6;
-       register int advance;
+       const struct ip6_hdr *ip6;
+       int advance;
        u_int len;
        const u_char *ipend;
-       register const u_char *cp;
-       register u_int payload_len;
+       const u_char *cp;
+       u_int payload_len;
        u_int nh;
        int fragmented = 0;
        u_int flow;
index 95e52e4bb9ec95c96eccc3414a14ee671079c264..00cad3912b413dc2dffb5d9e1583475bb682b4f9 100644 (file)
@@ -171,7 +171,7 @@ trunc:
 }
 
 int
-hbhopt_print(netdissect_options *ndo, register const u_char *bp)
+hbhopt_print(netdissect_options *ndo, const u_char *bp)
 {
     const struct ip6_hbh *dp = (const struct ip6_hbh *)bp;
     u_int hbhlen = 0;
@@ -191,7 +191,7 @@ hbhopt_print(netdissect_options *ndo, register const u_char *bp)
 }
 
 int
-dstopt_print(netdissect_options *ndo, register const u_char *bp)
+dstopt_print(netdissect_options *ndo, const u_char *bp)
 {
     const struct ip6_dest *dp = (const struct ip6_dest *)bp;
     u_int dstoptlen = 0;
index 8e5252b2192b0c65602fc5a30bbefea0bbd722c2..3d526d55c2aa0a10d5420a24d64a6274d636f388 100644 (file)
@@ -37,9 +37,9 @@ struct ipcomp {
 #include "extract.h"
 
 void
-ipcomp_print(netdissect_options *ndo, register const u_char *bp)
+ipcomp_print(netdissect_options *ndo, const u_char *bp)
 {
-       register const struct ipcomp *ipcomp;
+       const struct ipcomp *ipcomp;
        uint16_t cpi;
 
        ipcomp = (const struct ipcomp *)bp;
index 2ba51271876be554b9b3e54588be594baeabb798..b67e7f2d8e948a428ccb34d20d78eff77187a959 100644 (file)
@@ -59,9 +59,9 @@ extract_ipfc_addrs(const struct ipfc_header *ipfcp, char *ipfcsrc,
  */
 static inline void
 ipfc_hdr_print(netdissect_options *ndo,
-          register const struct ipfc_header *ipfcp _U_,
-          register u_int length, register const u_char *ipfcsrc,
-          register const u_char *ipfcdst)
+          const struct ipfc_header *ipfcp _U_,
+          u_int length, const u_char *ipfcsrc,
+          const u_char *ipfcdst)
 {
        const char *srcname, *dstname;
 
@@ -137,7 +137,7 @@ ipfc_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen)
  * is the number of bytes actually captured.
  */
 u_int
-ipfc_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, register const u_char *p)
+ipfc_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p)
 {
        return (ipfc_print(ndo, p, h->len, h->caplen));
 }
index ac0801219d20b73ecd9b60d825f10ad4afa3e617..9f3430f939a6eb0bf6855d935964c8bf46b7cd10 100644 (file)
@@ -111,7 +111,7 @@ ipxaddr_string(uint32_t net, const u_char *node)
 static void
 ipx_decode(netdissect_options *ndo, const struct ipxHdr *ipx, const u_char *datap, u_int length)
 {
-    register u_short dstSkt;
+    u_short dstSkt;
 
     dstSkt = EXTRACT_BE_U_2(&ipx->dstSkt);
     switch (dstSkt) {
index 55564579e5dd7b1be8ea30f2aeeb5c1188907c2b..2d88b604cd3052f6e4dedcc842deef0047e38bc8 100644 (file)
@@ -445,14 +445,14 @@ static const struct tok juniper_protocol_values[] = {
     { 0, NULL}
 };
 
-static int ip_heuristic_guess(netdissect_options *, register const u_char *, u_int);
-static int juniper_ppp_heuristic_guess(netdissect_options *, register const u_char *, u_int);
+static int ip_heuristic_guess(netdissect_options *, const u_char *, u_int);
+static int juniper_ppp_heuristic_guess(netdissect_options *, const u_char *, u_int);
 static int juniper_parse_header(netdissect_options *, const u_char *, const struct pcap_pkthdr *, struct juniper_l2info_t *);
 
 #ifdef DLT_JUNIPER_GGSN
 u_int
 juniper_ggsn_if_print(netdissect_options *ndo,
-                      const struct pcap_pkthdr *h, register const u_char *p)
+                      const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
         struct juniper_ggsn_header {
@@ -503,7 +503,7 @@ trunc:
 #ifdef DLT_JUNIPER_ES
 u_int
 juniper_es_if_print(netdissect_options *ndo,
-                    const struct pcap_pkthdr *h, register const u_char *p)
+                    const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
         struct juniper_ipsec_header {
@@ -580,7 +580,7 @@ trunc:
 #ifdef DLT_JUNIPER_MONITOR
 u_int
 juniper_monitor_if_print(netdissect_options *ndo,
-                         const struct pcap_pkthdr *h, register const u_char *p)
+                         const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
         struct juniper_monitor_header {
@@ -619,7 +619,7 @@ trunc:
 #ifdef DLT_JUNIPER_SERVICES
 u_int
 juniper_services_if_print(netdissect_options *ndo,
-                          const struct pcap_pkthdr *h, register const u_char *p)
+                          const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
         struct juniper_services_header {
@@ -659,7 +659,7 @@ trunc:
 #ifdef DLT_JUNIPER_PPPOE
 u_int
 juniper_pppoe_if_print(netdissect_options *ndo,
-                       const struct pcap_pkthdr *h, register const u_char *p)
+                       const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -677,7 +677,7 @@ juniper_pppoe_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_ETHER
 u_int
 juniper_ether_if_print(netdissect_options *ndo,
-                       const struct pcap_pkthdr *h, register const u_char *p)
+                       const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -695,7 +695,7 @@ juniper_ether_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_PPP
 u_int
 juniper_ppp_if_print(netdissect_options *ndo,
-                     const struct pcap_pkthdr *h, register const u_char *p)
+                     const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -713,7 +713,7 @@ juniper_ppp_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_FRELAY
 u_int
 juniper_frelay_if_print(netdissect_options *ndo,
-                        const struct pcap_pkthdr *h, register const u_char *p)
+                        const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -731,7 +731,7 @@ juniper_frelay_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_CHDLC
 u_int
 juniper_chdlc_if_print(netdissect_options *ndo,
-                       const struct pcap_pkthdr *h, register const u_char *p)
+                       const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -749,7 +749,7 @@ juniper_chdlc_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_PPPOE_ATM
 u_int
 juniper_pppoe_atm_if_print(netdissect_options *ndo,
-                           const struct pcap_pkthdr *h, register const u_char *p)
+                           const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
        uint16_t extracted_ethertype;
@@ -783,7 +783,7 @@ trunc:
 #ifdef DLT_JUNIPER_MLPPP
 u_int
 juniper_mlppp_if_print(netdissect_options *ndo,
-                       const struct pcap_pkthdr *h, register const u_char *p)
+                       const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -843,7 +843,7 @@ juniper_mlppp_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_MFR
 u_int
 juniper_mfr_if_print(netdissect_options *ndo,
-                     const struct pcap_pkthdr *h, register const u_char *p)
+                     const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -905,7 +905,7 @@ juniper_mfr_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_MLFR
 u_int
 juniper_mlfr_if_print(netdissect_options *ndo,
-                      const struct pcap_pkthdr *h, register const u_char *p)
+                      const struct pcap_pkthdr *h, const u_char *p)
 {
         struct juniper_l2info_t l2info;
 
@@ -948,7 +948,7 @@ juniper_mlfr_if_print(netdissect_options *ndo,
 #ifdef DLT_JUNIPER_ATM1
 u_int
 juniper_atm1_if_print(netdissect_options *ndo,
-                      const struct pcap_pkthdr *h, register const u_char *p)
+                      const struct pcap_pkthdr *h, const u_char *p)
 {
         int llc_hdrlen;
 
@@ -1002,7 +1002,7 @@ trunc:
 #ifdef DLT_JUNIPER_ATM2
 u_int
 juniper_atm2_if_print(netdissect_options *ndo,
-                      const struct pcap_pkthdr *h, register const u_char *p)
+                      const struct pcap_pkthdr *h, const u_char *p)
 {
         int llc_hdrlen;
 
@@ -1059,7 +1059,7 @@ trunc:
  * a juniper router if the payload data is encapsulated using PPP */
 static int
 juniper_ppp_heuristic_guess(netdissect_options *ndo,
-                            register const u_char *p, u_int length)
+                            const u_char *p, u_int length)
 {
     switch(EXTRACT_BE_U_2(p)) {
     case PPP_IP :
@@ -1087,7 +1087,7 @@ juniper_ppp_heuristic_guess(netdissect_options *ndo,
 
 static int
 ip_heuristic_guess(netdissect_options *ndo,
-                   register const u_char *p, u_int length)
+                   const u_char *p, u_int length)
 {
     switch(EXTRACT_U_1(p)) {
     case 0x45:
index de025f9300f40b893c558280b9beb21e6fd574a7..b6c78298a389bf64562a8f4363316a5e28812e11 100644 (file)
@@ -51,7 +51,7 @@
 
 static const char tstr[] = " [|kerberos]";
 
-static const u_char *c_print(netdissect_options *, register const u_char *, register const u_char *);
+static const u_char *c_print(netdissect_options *, const u_char *, const u_char *);
 static const u_char *krb4_print_hdr(netdissect_options *, const u_char *);
 static void krb4_print(netdissect_options *, const u_char *);
 
@@ -112,10 +112,10 @@ static const struct tok kerr2str[] = {
 
 static const u_char *
 c_print(netdissect_options *ndo,
-        register const u_char *s, register const u_char *ep)
+        const u_char *s, const u_char *ep)
 {
-       register u_char c;
-       register int flag;
+       u_char c;
+       int flag;
 
        flag = 1;
        while (s < ep) {
@@ -166,7 +166,7 @@ static void
 krb4_print(netdissect_options *ndo,
            const u_char *cp)
 {
-       register const struct krb *kp;
+       const struct krb *kp;
        u_char type;
        u_short len;
 
@@ -247,7 +247,7 @@ void
 krb_print(netdissect_options *ndo,
           const u_char *dat)
 {
-       register const struct krb *kp;
+       const struct krb *kp;
 
        kp = (const struct krb *)dat;
 
index e107c52b6ebf062176b9d3d5498c03a91afef7ca..ab4f6c631e3c5b5f6779eb38c6b48a9ca5d41879 100644 (file)
@@ -210,7 +210,7 @@ static const struct tok ldp_fec_martini_ifparm_vccv_cv_values[] = {
     { 0, NULL}
 };
 
-static int ldp_pdu_print(netdissect_options *, register const u_char *);
+static int ldp_pdu_print(netdissect_options *, const u_char *);
 
 /*
  * ldp tlv header
@@ -234,7 +234,7 @@ static int ldp_pdu_print(netdissect_options *, register const u_char *);
 
 static int
 ldp_tlv_print(netdissect_options *ndo,
-              register const u_char *tptr,
+              const u_char *tptr,
               u_short msg_tlen)
 {
     struct ldp_tlv_header {
@@ -544,7 +544,7 @@ badtlv:
 
 void
 ldp_print(netdissect_options *ndo,
-          register const u_char *pptr, register u_int len)
+          const u_char *pptr, u_int len)
 {
     int processed;
     while (len > (sizeof(struct ldp_common_header) + sizeof(struct ldp_msg_header))) {
@@ -558,7 +558,7 @@ ldp_print(netdissect_options *ndo,
 
 static int
 ldp_pdu_print(netdissect_options *ndo,
-              register const u_char *pptr)
+              const u_char *pptr)
 {
     const struct ldp_common_header *ldp_com_header;
     const struct ldp_msg_header *ldp_msg_header;
index cd368b3f39de33befd325a97db8b214ac4da3a42..3d0a7cd0fcfb34746199808c6a2b5107d734b283 100644 (file)
@@ -424,8 +424,8 @@ snap_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen,
        u_int bridge_pad)
 {
        uint32_t orgcode;
-       register u_short et;
-       register int ret;
+       u_short et;
+       int ret;
 
        ND_TCHECK_5(p);
        if (caplen < 5 || length < 5)
index 90dba8ee8da80b9fe358c9ccdabb9f00758d9544..f4752d49b9835f16d7fc48b26dac280985e095a4 100644 (file)
@@ -1425,7 +1425,7 @@ lldp_mgmt_addr_tlv_print(netdissect_options *ndo,
 
 void
 lldp_print(netdissect_options *ndo,
-           register const u_char *pptr, register u_int len)
+           const u_char *pptr, u_int len)
 {
     uint8_t subtype;
     uint16_t tlv, cap, ena_cap;
index 295c02421e3e80ac52d16ed4473e3a573c93355f..4acd8890dd0f0e136476692de2f096ce78ec959e 100644 (file)
@@ -423,7 +423,7 @@ lmp_print_data_link_subobjs(netdissect_options *ndo, const u_char *obj_tptr,
 
 void
 lmp_print(netdissect_options *ndo,
-          register const u_char *pptr, register u_int len)
+          const u_char *pptr, u_int len)
 {
     const struct lmp_common_header *lmp_com_header;
     const struct lmp_object_header *lmp_obj_header;
index f32bbde7625fb371d815aded4914484f03a8de03..09e8317f4fa100ca3e2049700b8c8be7f41340ac 100644 (file)
@@ -487,7 +487,7 @@ static const struct tok lspping_tlv_downstream_addr_values[] = {
 
 void
 lspping_print(netdissect_options *ndo,
-              register const u_char *pptr, register u_int len)
+              const u_char *pptr, u_int len)
 {
     const struct lspping_common_header *lspping_com_header;
     const struct lspping_tlv_header *lspping_tlv_header;
index ff6d908c8a2077541a3a0e861b85c282c80145dc..f6793a61bbc40961c83e0ea0961af1bbc916e7ea 100644 (file)
@@ -290,7 +290,7 @@ lwres_printaddr(netdissect_options *ndo,
 
 void
 lwres_print(netdissect_options *ndo,
-            register const u_char *bp, u_int length)
+            const u_char *bp, u_int length)
 {
        const struct lwres_lwpacket *np;
        uint32_t v;
index 1f6446e39b1ca146ffb76f049f93dbc1b29f5954..8f988357bc07bb84d4d1fcfee535baf3ff7677fd 100644 (file)
@@ -121,7 +121,7 @@ static const struct tok mpcp_reg_ack_flag_values[] = {
 };
 
 void
-mpcp_print(netdissect_options *ndo, register const u_char *pptr, register u_int length)
+mpcp_print(netdissect_options *ndo, const u_char *pptr, u_int length)
 {
     union {
         const struct mpcp_common_header_t *common_header;
index 797f53ad9428559c5315feec83dc6c83dbbd3d61..45b42787be0f4f8e36922892aac157558af32523 100644 (file)
@@ -320,10 +320,10 @@ print_sattr3(netdissect_options *ndo,
 
 void
 nfsreply_print(netdissect_options *ndo,
-               register const u_char *bp, u_int length,
-               register const u_char *bp2)
+               const u_char *bp, u_int length,
+               const u_char *bp2)
 {
-       register const struct sunrpc_msg *rp;
+       const struct sunrpc_msg *rp;
        char srcid[20], dstid[20];      /*fits 32bit*/
 
        nfserr = 0;             /* assume no error */
@@ -351,10 +351,10 @@ trunc:
 
 void
 nfsreply_noaddr_print(netdissect_options *ndo,
-                      register const u_char *bp, u_int length,
-                      register const u_char *bp2)
+                      const u_char *bp, u_int length,
+                      const u_char *bp2)
 {
-       register const struct sunrpc_msg *rp;
+       const struct sunrpc_msg *rp;
        uint32_t proc, vers, reply_stat;
        enum sunrpc_reject_stat rstat;
        uint32_t rlow;
@@ -416,10 +416,10 @@ trunc:
  */
 static const uint32_t *
 parsereq(netdissect_options *ndo,
-         register const struct sunrpc_msg *rp, register u_int length)
+         const struct sunrpc_msg *rp, u_int length)
 {
-       register const uint32_t *dp;
-       register u_int len;
+       const uint32_t *dp;
+       u_int len;
 
        /*
         * find the start of the req data (if we captured it)
@@ -447,7 +447,7 @@ trunc:
  */
 static const uint32_t *
 parsefh(netdissect_options *ndo,
-        register const uint32_t *dp, int v3)
+        const uint32_t *dp, int v3)
 {
        u_int len;
 
@@ -472,10 +472,10 @@ trunc:
  */
 static const uint32_t *
 parsefn(netdissect_options *ndo,
-        register const uint32_t *dp)
+        const uint32_t *dp)
 {
-       register uint32_t len;
-       register const u_char *cp;
+       uint32_t len;
+       const u_char *cp;
 
        /* Bail if we don't have the string length */
        ND_TCHECK(*dp);
@@ -508,7 +508,7 @@ trunc:
  */
 static const uint32_t *
 parsefhn(netdissect_options *ndo,
-         register const uint32_t *dp, int v3)
+         const uint32_t *dp, int v3)
 {
        dp = parsefh(ndo, dp, v3);
        if (dp == NULL)
@@ -519,11 +519,11 @@ parsefhn(netdissect_options *ndo,
 
 void
 nfsreq_noaddr_print(netdissect_options *ndo,
-                    register const u_char *bp, u_int length,
-                    register const u_char *bp2)
+                    const u_char *bp, u_int length,
+                    const u_char *bp2)
 {
-       register const struct sunrpc_msg *rp;
-       register const uint32_t *dp;
+       const struct sunrpc_msg *rp;
+       const uint32_t *dp;
        nfs_type type;
        int v3;
        uint32_t proc;
@@ -783,7 +783,7 @@ trunc:
  */
 static void
 nfs_printfh(netdissect_options *ndo,
-            register const uint32_t *dp, const u_int len)
+            const uint32_t *dp, const u_int len)
 {
        my_fsid fsid;
        uint32_t ino;
@@ -974,9 +974,9 @@ xid_map_find(const struct sunrpc_msg *rp, const u_char *bp, uint32_t *proc,
  */
 static const uint32_t *
 parserep(netdissect_options *ndo,
-         register const struct sunrpc_msg *rp, register u_int length)
+         const struct sunrpc_msg *rp, u_int length)
 {
-       register const uint32_t *dp;
+       const uint32_t *dp;
        u_int len;
        enum sunrpc_accept_stat astat;
 
@@ -1447,8 +1447,8 @@ static void
 interp_reply(netdissect_options *ndo,
              const struct sunrpc_msg *rp, uint32_t proc, uint32_t vers, int length)
 {
-       register const uint32_t *dp;
-       register int v3;
+       const uint32_t *dp;
+       int v3;
        int er;
 
        v3 = (vers == NFS_VER3);
index c482697deb37b20ea459590a6662333f6db85e54..58d9843d25adaece64ca30e9f190239b4814a8da 100644 (file)
@@ -189,7 +189,7 @@ struct ntp_time_data {
 static void p_sfix(netdissect_options *ndo, const struct s_fixedpt *);
 static void p_ntp_time(netdissect_options *, const struct l_fixedpt *);
 static void p_ntp_delta(netdissect_options *, const struct l_fixedpt *, const struct l_fixedpt *);
-static void p_poll(netdissect_options *, register const int);
+static void p_poll(netdissect_options *, const int);
 
 static const struct tok ntp_mode_values[] = {
     { MODE_UNSPEC,    "unspecified" },
@@ -262,7 +262,7 @@ struct ntp_control_data {
  */
 static void
 ntp_time_print(netdissect_options *ndo,
-              register const struct ntp_time_data *bp, u_int length)
+              const struct ntp_time_data *bp, u_int length)
 {
        uint8_t stratum;
 
@@ -385,7 +385,7 @@ trunc:
  */
 static void
 ntp_control_print(netdissect_options *ndo,
-                 register const struct ntp_control_data *cd, u_int length)
+                 const struct ntp_control_data *cd, u_int length)
 {
        uint8_t control, R, E, M, opcode;
        uint16_t sequence, status, assoc, offset, count;
@@ -450,9 +450,9 @@ union ntpdata {
  */
 void
 ntp_print(netdissect_options *ndo,
-          register const u_char *cp, u_int length)
+          const u_char *cp, u_int length)
 {
-       register const union ntpdata *bp = (const union ntpdata *)cp;
+       const union ntpdata *bp = (const union ntpdata *)cp;
        int mode, version, leapind;
        uint8_t status;
 
@@ -493,11 +493,11 @@ trunc:
 
 static void
 p_sfix(netdissect_options *ndo,
-       register const struct s_fixedpt *sfp)
+       const struct s_fixedpt *sfp)
 {
-       register int i;
-       register int f;
-       register double ff;
+       int i;
+       int f;
+       double ff;
 
        i = EXTRACT_BE_U_2(&sfp->int_part);
        f = EXTRACT_BE_U_2(&sfp->fraction);
@@ -510,12 +510,12 @@ p_sfix(netdissect_options *ndo,
 
 static void
 p_ntp_time(netdissect_options *ndo,
-           register const struct l_fixedpt *lfp)
+           const struct l_fixedpt *lfp)
 {
-       register uint32_t i;
-       register uint32_t uf;
-       register uint32_t f;
-       register double ff;
+       uint32_t i;
+       uint32_t uf;
+       uint32_t f;
+       double ff;
 
        i = EXTRACT_BE_U_4(&lfp->int_part);
        uf = EXTRACT_BE_U_4(&lfp->fraction);
@@ -565,14 +565,14 @@ p_ntp_time(netdissect_options *ndo,
 /* Prints time difference between *lfp and *olfp */
 static void
 p_ntp_delta(netdissect_options *ndo,
-            register const struct l_fixedpt *olfp,
-            register const struct l_fixedpt *lfp)
+            const struct l_fixedpt *olfp,
+            const struct l_fixedpt *lfp)
 {
-       register int32_t i;
-       register uint32_t u, uf;
-       register uint32_t ou, ouf;
-       register uint32_t f;
-       register double ff;
+       int32_t i;
+       uint32_t u, uf;
+       uint32_t ou, ouf;
+       uint32_t f;
+       double ff;
        int signbit;
 
        u = EXTRACT_BE_U_4(&lfp->int_part);
@@ -618,7 +618,7 @@ p_ntp_delta(netdissect_options *ndo,
 /* Prints polling interval in log2 as seconds or fraction of second */
 static void
 p_poll(netdissect_options *ndo,
-       register const int poll_interval)
+       const int poll_interval)
 {
        if (poll_interval <= -32 || poll_interval >= 32)
                return;
index 4453a47e3bee024a59596d452346e8037a6957a1..025d97e1c13af580e4a25d6af92342f3a017e5b1 100644 (file)
@@ -510,7 +510,7 @@ invalid:
 
 static int
 ospf_print_lshdr(netdissect_options *ndo,
-                 register const struct lsa_hdr *lshp)
+                 const struct lsa_hdr *lshp)
 {
         u_int ls_length;
 
@@ -612,16 +612,16 @@ trunc:
  */
 static const uint8_t *
 ospf_print_lsa(netdissect_options *ndo,
-               register const struct lsa *lsap)
+               const struct lsa *lsap)
 {
-       register const uint8_t *ls_end;
-       register const struct rlalink *rlp;
-       register const struct in_addr *ap;
-       register const struct aslametric *almp;
-       register const struct mcla *mcp;
-       register const uint32_t *lp;
-       register int j, tlv_type, tlv_length, topology;
-       register int ls_length;
+       const uint8_t *ls_end;
+       const struct rlalink *rlp;
+       const struct in_addr *ap;
+       const struct aslametric *almp;
+       const struct mcla *mcp;
+       const uint32_t *lp;
+       int j, tlv_type, tlv_length, topology;
+       int ls_length;
        const uint8_t *tptr;
 
        tptr = (const uint8_t *)lsap->lsa_un.un_unknown; /* squelch compiler warnings */
@@ -703,7 +703,7 @@ ospf_print_lsa(netdissect_options *ndo,
                ND_TCHECK(lsap->lsa_un.un_sla.sla_tosmetric);
                lp = lsap->lsa_un.un_sla.sla_tosmetric;
                while ((const u_char *)lp < ls_end) {
-                       register uint32_t ul;
+                       uint32_t ul;
 
                        ND_TCHECK(*lp);
                        ul = EXTRACT_BE_U_4(lp);
@@ -720,7 +720,7 @@ ospf_print_lsa(netdissect_options *ndo,
                ND_TCHECK(lsap->lsa_un.un_sla.sla_tosmetric);
                lp = lsap->lsa_un.un_sla.sla_tosmetric;
                while ((const u_char *)lp < ls_end) {
-                       register uint32_t ul;
+                       uint32_t ul;
 
                        ND_TCHECK(*lp);
                        ul = EXTRACT_BE_U_4(lp);
@@ -742,7 +742,7 @@ ospf_print_lsa(netdissect_options *ndo,
                ND_TCHECK(lsap->lsa_un.un_sla.sla_tosmetric);
                almp = lsap->lsa_un.un_asla.asla_metric;
                while ((const u_char *)almp < ls_end) {
-                       register uint32_t ul;
+                       uint32_t ul;
 
                        ND_TCHECK(almp->asla_tosmetric);
                        ul = EXTRACT_BE_U_4(&almp->asla_tosmetric);
@@ -885,13 +885,13 @@ trunc:
 
 static int
 ospf_decode_lls(netdissect_options *ndo,
-                register const struct ospfhdr *op, register u_int length)
+                const struct ospfhdr *op, u_int length)
 {
-    register const u_char *dptr;
-    register const u_char *dataend;
-    register u_int length2;
-    register uint16_t lls_type, lls_len;
-    register uint32_t lls_flags;
+    const u_char *dptr;
+    const u_char *dataend;
+    u_int length2;
+    uint16_t lls_type, lls_len;
+    uint32_t lls_flags;
 
     switch (op->ospf_type) {
 
@@ -977,13 +977,13 @@ trunc:
 
 static int
 ospf_decode_v2(netdissect_options *ndo,
-               register const struct ospfhdr *op, register const u_char *dataend)
+               const struct ospfhdr *op, const u_char *dataend)
 {
-       register const struct in_addr *ap;
-       register const struct lsr *lsrp;
-       register const struct lsa_hdr *lshp;
-       register const struct lsa *lsap;
-       register uint32_t lsa_count,lsa_count_max;
+       const struct in_addr *ap;
+       const struct lsr *lsrp;
+       const struct lsa_hdr *lshp;
+       const struct lsa *lsap;
+       uint32_t lsa_count,lsa_count_max;
 
        switch (op->ospf_type) {
 
@@ -1100,12 +1100,12 @@ trunc:
 
 void
 ospf_print(netdissect_options *ndo,
-           register const u_char *bp, register u_int length,
+           const u_char *bp, u_int length,
            const u_char *bp2 _U_)
 {
-       register const struct ospfhdr *op;
-       register const u_char *dataend;
-       register const char *cp;
+       const struct ospfhdr *op;
+       const u_char *dataend;
+       const char *cp;
 
        op = (const struct ospfhdr *)bp;
 
index 68c6ee03342cf144bccff914d60ddd5e1da83539..e38c455708195f3048a0a653fccec13873d06829 100644 (file)
@@ -373,7 +373,7 @@ static const struct tok ospf6_auth_type_str[] = {
 
 static void
 ospf6_print_ls_type(netdissect_options *ndo,
-                    register u_int ls_type, register const rtrid_t *ls_stateid)
+                    u_int ls_type, const rtrid_t *ls_stateid)
 {
         ND_PRINT((ndo, "\n\t    %s LSA (%d), %s Scope%s, LSA-ID %s",
                tok2str(ospf6_lsa_values, "Unknown", ls_type & LS_TYPE_MASK),
@@ -385,7 +385,7 @@ ospf6_print_ls_type(netdissect_options *ndo,
 
 static int
 ospf6_print_lshdr(netdissect_options *ndo,
-                  register const struct lsa6_hdr *lshp, const u_char *dataend)
+                  const struct lsa6_hdr *lshp, const u_char *dataend)
 {
        if ((const u_char *)(lshp + 1) > dataend)
                goto trunc;
@@ -449,25 +449,25 @@ trunc:
  */
 static int
 ospf6_print_lsa(netdissect_options *ndo,
-                register const struct lsa6 *lsap, const u_char *dataend)
+                const struct lsa6 *lsap, const u_char *dataend)
 {
-       register const struct rlalink6 *rlp;
+       const struct rlalink6 *rlp;
 #if 0
-       register const struct tos_metric *tosp;
+       const struct tos_metric *tosp;
 #endif
-       register const rtrid_t *ap;
+       const rtrid_t *ap;
 #if 0
-       register const struct aslametric *almp;
-       register const struct mcla *mcp;
+       const struct aslametric *almp;
+       const struct mcla *mcp;
 #endif
-       register const struct llsa *llsap;
-       register const struct lsa6_prefix *lsapp;
+       const struct llsa *llsap;
+       const struct lsa6_prefix *lsapp;
 #if 0
-       register const uint32_t *lp;
+       const uint32_t *lp;
 #endif
-       register u_int prefixes;
-       register int bytelen;
-       register u_int length, lsa_length;
+       u_int prefixes;
+       int bytelen;
+       u_int length, lsa_length;
        uint32_t flags32;
        const uint8_t *tptr;
 
@@ -723,19 +723,19 @@ trunc:
 
 static int
 ospf6_decode_v3(netdissect_options *ndo,
-                register const struct ospf6hdr *op,
-                register const u_char *dataend)
+                const struct ospf6hdr *op,
+                const u_char *dataend)
 {
-       register const rtrid_t *ap;
-       register const struct lsr6 *lsrp;
-       register const struct lsa6_hdr *lshp;
-       register const struct lsa6 *lsap;
-       register int i;
+       const rtrid_t *ap;
+       const struct lsr6 *lsrp;
+       const struct lsa6_hdr *lshp;
+       const struct lsa6 *lsap;
+       int i;
 
        switch (op->ospf6_type) {
 
        case OSPF_TYPE_HELLO: {
-               register const struct hello6 *hellop = (const struct hello6 *)((const uint8_t *)op + OSPF6HDR_LEN);
+               const struct hello6 *hellop = (const struct hello6 *)((const uint8_t *)op + OSPF6HDR_LEN);
 
                ND_TCHECK_4(&hellop->hello_options);
                ND_PRINT((ndo, "\n\tOptions [%s]",
@@ -770,7 +770,7 @@ ospf6_decode_v3(netdissect_options *ndo,
        }
 
        case OSPF_TYPE_DD: {
-               register const struct dd6 *ddp = (const struct dd6 *)((const uint8_t *)op + OSPF6HDR_LEN);
+               const struct dd6 *ddp = (const struct dd6 *)((const uint8_t *)op + OSPF6HDR_LEN);
 
                ND_TCHECK(ddp->db_options);
                ND_PRINT((ndo, "\n\tOptions [%s]",
@@ -812,7 +812,7 @@ ospf6_decode_v3(netdissect_options *ndo,
 
        case OSPF_TYPE_LS_UPDATE:
                if (ndo->ndo_vflag > 1) {
-                       register const struct lsu6 *lsup = (const struct lsu6 *)((const uint8_t *)op + OSPF6HDR_LEN);
+                       const struct lsu6 *lsup = (const struct lsu6 *)((const uint8_t *)op + OSPF6HDR_LEN);
 
                        ND_TCHECK(lsup->lsu_count);
                        i = EXTRACT_BE_U_4(&lsup->lsu_count);
@@ -956,11 +956,11 @@ trunc:
 
 void
 ospf6_print(netdissect_options *ndo,
-            register const u_char *bp, register u_int length)
+            const u_char *bp, u_int length)
 {
-       register const struct ospf6hdr *op;
-       register const u_char *dataend;
-       register const char *cp;
+       const struct ospf6hdr *op;
+       const u_char *dataend;
+       const char *cp;
        uint16_t datalen;
 
        op = (const struct ospf6hdr *)bp;
index d53fea81685c0d590d4e76250fda9cf44437a4b5..d0269af04ab4fc5ac17675519529cca55cc86122 100644 (file)
@@ -106,7 +106,7 @@ pflog_print(netdissect_options *ndo, const struct pfloghdr *hdr)
 
 u_int
 pflog_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h,
-               register const u_char *p)
+               const u_char *p)
 {
        u_int length = h->len;
        u_int hdrlen;
index 04b654ef23ef0a6e54d569b7badb6a925b44d623..1cf9bd20dd8f8a01c9c685f9a35004f61e19b678 100644 (file)
@@ -144,16 +144,16 @@ typedef enum _pgm_type {
 
 void
 pgm_print(netdissect_options *ndo,
-          register const u_char *bp, register u_int length,
-          register const u_char *bp2)
+          const u_char *bp, u_int length,
+          const u_char *bp2)
 {
-       register const struct pgm_header *pgm;
-       register const struct ip *ip;
-       register char ch;
+       const struct pgm_header *pgm;
+       const struct ip *ip;
+       char ch;
        uint16_t sport, dport;
        u_int nla_afnum;
        char nla_buf[INET6_ADDRSTRLEN];
-       register const struct ip6_hdr *ip6;
+       const struct ip6_hdr *ip6;
        uint8_t opt_type, opt_len;
        uint32_t seq, opts_len, len, offset;
 
index c479c7b0e22411716c5882195bcb4e84ffe0f252..8e52de5a2843b7ebf37660df904a0ba18d05b4bd 100644 (file)
@@ -137,11 +137,11 @@ struct pim {
        u_short pim_cksum;      /* IP style check sum */
 };
 
-static void pimv2_print(netdissect_options *, register const u_char *bp, register u_int len, const u_char *);
+static void pimv2_print(netdissect_options *, const u_char *bp, u_int len, const u_char *);
 
 static void
 pimv1_join_prune_print(netdissect_options *ndo,
-                       register const u_char *bp, register u_int len)
+                       const u_char *bp, u_int len)
 {
        int ngroups, njoin, nprune;
        int njp;
@@ -249,9 +249,9 @@ trunc:
 
 void
 pimv1_print(netdissect_options *ndo,
-            register const u_char *bp, register u_int len)
+            const u_char *bp, u_int len)
 {
-       register u_char type;
+       u_char type;
 
        ND_TCHECK_1(bp + 1);
        type = EXTRACT_U_1(bp + 1);
@@ -343,7 +343,7 @@ trunc:
  */
 void
 cisco_autorp_print(netdissect_options *ndo,
-                   register const u_char *bp, register u_int len)
+                   const u_char *bp, u_int len)
 {
        int type;
        int numrps;
@@ -453,9 +453,9 @@ trunc:
 
 void
 pim_print(netdissect_options *ndo,
-          register const u_char *bp, register u_int len, const u_char *bp2)
+          const u_char *bp, u_int len, const u_char *bp2)
 {
-       register const struct pim *pim = (const struct pim *)bp;
+       const struct pim *pim = (const struct pim *)bp;
 
 #ifdef notyet                  /* currently we see only version and type */
        ND_TCHECK(pim->pim_rsv);
@@ -692,9 +692,9 @@ pimv2_check_checksum(netdissect_options *ndo, const u_char *bp,
 
 static void
 pimv2_print(netdissect_options *ndo,
-            register const u_char *bp, register u_int len, const u_char *bp2)
+            const u_char *bp, u_int len, const u_char *bp2)
 {
-       register const struct pim *pim = (const struct pim *)bp;
+       const struct pim *pim = (const struct pim *)bp;
        int advance;
        enum checksum_status cksum_status;
        int pimv2_addr_len;
index a79906f83eb4c7136669ee8d4087e7588a54ef57..3b935ed59d4373d0a3fb3e1549fe5ce756099eea 100644 (file)
@@ -1539,7 +1539,7 @@ handle_ppp(netdissect_options *ndo,
 /* Standard PPP printer */
 u_int
 ppp_print(netdissect_options *ndo,
-          register const u_char *p, u_int length)
+          const u_char *p, u_int length)
 {
        u_int proto,ppp_header;
         u_int olen = length; /* _o_riginal length */
@@ -1610,10 +1610,10 @@ trunc:
 /* PPP I/F printer */
 u_int
 ppp_if_print(netdissect_options *ndo,
-             const struct pcap_pkthdr *h, register const u_char *p)
+             const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
 
        if (caplen < PPP_HDRLEN) {
                ND_PRINT((ndo, "[|ppp]"));
@@ -1678,10 +1678,10 @@ ppp_if_print(netdissect_options *ndo,
  */
 u_int
 ppp_hdlc_if_print(netdissect_options *ndo,
-                  const struct pcap_pkthdr *h, register const u_char *p)
+                  const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
        u_int proto;
        u_int hdrlen = 0;
 
@@ -1748,12 +1748,12 @@ ppp_hdlc_if_print(netdissect_options *ndo,
 /* BSD/OS specific PPP printer */
 u_int
 ppp_bsdos_if_print(netdissect_options *ndo _U_,
-                   const struct pcap_pkthdr *h _U_, register const u_char *p _U_)
+                   const struct pcap_pkthdr *h _U_, const u_char *p _U_)
 {
-       register u_int hdrlength;
+       u_int hdrlength;
 #ifdef __bsdi__
-       register u_int length = h->len;
-       register u_int caplen = h->caplen;
+       u_int length = h->len;
+       u_int caplen = h->caplen;
        uint16_t ptype;
        uint8_t llhl;
        const u_char *q;
index b2efcc321eaca619ae2a86d1e4c04735b4dcda41..fe10839695c85a67d48cffc21feb616a7713f6ad 100644 (file)
@@ -85,13 +85,13 @@ static const struct tok pppoetag2str[] = {
 #define MAXTAGPRINT 80
 
 u_int
-pppoe_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, register const u_char *p)
+pppoe_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p)
 {
        return (pppoe_print(ndo, p, h->len));
 }
 
 u_int
-pppoe_print(netdissect_options *ndo, register const u_char *bp, u_int length)
+pppoe_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
        uint16_t pppoe_ver, pppoe_type, pppoe_code, pppoe_sessionid;
        u_int pppoe_length;
index 904f659495af7beedf653a5f88badec0c6252266..9047cd14363abd31aa178eeb6800ad838978702b 100644 (file)
@@ -191,14 +191,14 @@ static const struct tok rfc4675_tagged[] = {
 };
 
 
-static void print_attr_string(netdissect_options *, register const u_char *, u_int, u_short );
-static void print_attr_num(netdissect_options *, register const u_char *, u_int, u_short );
-static void print_vendor_attr(netdissect_options *, register const u_char *, u_int, u_short );
-static void print_attr_address(netdissect_options *, register const u_char *, u_int, u_short);
-static void print_attr_address6(netdissect_options *, register const u_char *, u_int, u_short);
-static void print_attr_netmask6(netdissect_options *, register const u_char *, u_int, u_short);
-static void print_attr_time(netdissect_options *, register const u_char *, u_int, u_short);
-static void print_attr_strange(netdissect_options *, register const u_char *, u_int, u_short);
+static void print_attr_string(netdissect_options *, const u_char *, u_int, u_short );
+static void print_attr_num(netdissect_options *, const u_char *, u_int, u_short );
+static void print_vendor_attr(netdissect_options *, const u_char *, u_int, u_short );
+static void print_attr_address(netdissect_options *, const u_char *, u_int, u_short);
+static void print_attr_address6(netdissect_options *, const u_char *, u_int, u_short);
+static void print_attr_netmask6(netdissect_options *, const u_char *, u_int, u_short);
+static void print_attr_time(netdissect_options *, const u_char *, u_int, u_short);
+static void print_attr_strange(netdissect_options *, const u_char *, u_int, u_short);
 
 
 struct radius_hdr { uint8_t  code; /* Radius packet code  */
@@ -443,7 +443,7 @@ static struct attrtype {
                   const char **subtypes; /* Standard Values (if any)       */
                   u_char siz_subtypes;   /* Size of total standard values  */
                   u_char first_subtype;  /* First standard value is 0 or 1 */
-                  void (*print_func)(netdissect_options *, register const u_char *, u_int, u_short);
+                  void (*print_func)(netdissect_options *, const u_char *, u_int, u_short);
                 } attr_type[]=
   {
      { NULL,                              NULL, 0, 0, NULL               },
@@ -582,9 +582,9 @@ static struct attrtype {
 /*****************************/
 static void
 print_attr_string(netdissect_options *ndo,
-                  register const u_char *data, u_int length, u_short attr_code)
+                  const u_char *data, u_int length, u_short attr_code)
 {
-   register u_int i;
+   u_int i;
 
    ND_TCHECK_LEN(data, length);
 
@@ -646,7 +646,7 @@ print_attr_string(netdissect_options *ndo,
  */
 static void
 print_vendor_attr(netdissect_options *ndo,
-                  register const u_char *data, u_int length, u_short attr_code _U_)
+                  const u_char *data, u_int length, u_short attr_code _U_)
 {
     u_int idx;
     u_int vendor_id;
@@ -711,7 +711,7 @@ print_vendor_attr(netdissect_options *ndo,
 /******************************/
 static void
 print_attr_num(netdissect_options *ndo,
-               register const u_char *data, u_int length, u_short attr_code)
+               const u_char *data, u_int length, u_short attr_code)
 {
    uint32_t timeout;
 
@@ -834,7 +834,7 @@ print_attr_num(netdissect_options *ndo,
 /*****************************/
 static void
 print_attr_address(netdissect_options *ndo,
-                   register const u_char *data, u_int length, u_short attr_code)
+                   const u_char *data, u_int length, u_short attr_code)
 {
    if (length != 4)
    {
@@ -877,7 +877,7 @@ print_attr_address(netdissect_options *ndo,
 /*****************************/
 static void
 print_attr_address6(netdissect_options *ndo,
-                   register const u_char *data, u_int length, u_short attr_code _U_)
+                   const u_char *data, u_int length, u_short attr_code _U_)
 {
    if (length != 16)
    {
@@ -897,7 +897,7 @@ print_attr_address6(netdissect_options *ndo,
 
 static void
 print_attr_netmask6(netdissect_options *ndo,
-                    register const u_char *data, u_int length, u_short attr_code _U_)
+                    const u_char *data, u_int length, u_short attr_code _U_)
 {
    u_char data2[16];
 
@@ -938,7 +938,7 @@ print_attr_netmask6(netdissect_options *ndo,
 /*************************************/
 static void
 print_attr_time(netdissect_options *ndo,
-                register const u_char *data, u_int length, u_short attr_code _U_)
+                const u_char *data, u_int length, u_short attr_code _U_)
 {
    time_t attr_time;
    char string[26];
@@ -971,7 +971,7 @@ print_attr_time(netdissect_options *ndo,
 /***********************************/
 static void
 print_attr_strange(netdissect_options *ndo,
-                   register const u_char *data, u_int length, u_short attr_code)
+                   const u_char *data, u_int length, u_short attr_code)
 {
    u_short len_data;
    u_int error_cause_value;
@@ -1055,9 +1055,9 @@ print_attr_strange(netdissect_options *ndo,
 
 static void
 radius_attrs_print(netdissect_options *ndo,
-                   register const u_char *attr, u_int length)
+                   const u_char *attr, u_int length)
 {
-   register const struct radius_attr *rad_attr = (const struct radius_attr *)attr;
+   const struct radius_attr *rad_attr = (const struct radius_attr *)attr;
    const char *attr_string;
 
    while (length > 0)
@@ -1118,7 +1118,7 @@ void
 radius_print(netdissect_options *ndo,
              const u_char *dat, u_int length)
 {
-   register const struct radius_hdr *rad;
+   const struct radius_hdr *rad;
    u_int len, auth_idx;
 
    ND_TCHECK_LEN(dat, MIN_RADIUS_LEN);
index 736b933eeed246dc5374acb31d740162606e85b8..1d24b58e660e6de691603f6cc4557c3dd5b15e40 100644 (file)
@@ -61,15 +61,15 @@ static const char tstr[] = " [|RESP]";
 #define resp_print_invalid(ndo)          ND_PRINT((ndo, " invalid"))
 
 void       resp_print(netdissect_options *, const u_char *, u_int);
-static int resp_parse(netdissect_options *, register const u_char *, int);
-static int resp_print_string_error_integer(netdissect_options *, register const u_char *, int);
-static int resp_print_simple_string(netdissect_options *, register const u_char *, int);
-static int resp_print_integer(netdissect_options *, register const u_char *, int);
-static int resp_print_error(netdissect_options *, register const u_char *, int);
-static int resp_print_bulk_string(netdissect_options *, register const u_char *, int);
-static int resp_print_bulk_array(netdissect_options *, register const u_char *, int);
-static int resp_print_inline(netdissect_options *, register const u_char *, int);
-static int resp_get_length(netdissect_options *, register const u_char *, int, const u_char **);
+static int resp_parse(netdissect_options *, const u_char *, int);
+static int resp_print_string_error_integer(netdissect_options *, const u_char *, int);
+static int resp_print_simple_string(netdissect_options *, const u_char *, int);
+static int resp_print_integer(netdissect_options *, const u_char *, int);
+static int resp_print_error(netdissect_options *, const u_char *, int);
+static int resp_print_bulk_string(netdissect_options *, const u_char *, int);
+static int resp_print_bulk_array(netdissect_options *, const u_char *, int);
+static int resp_print_inline(netdissect_options *, const u_char *, int);
+static int resp_get_length(netdissect_options *, const u_char *, int, const u_char **);
 
 #define LCHECK2(_tot_len, _len) \
     {                           \
@@ -241,7 +241,7 @@ trunc:
 }
 
 static int
-resp_parse(netdissect_options *ndo, register const u_char *bp, int length)
+resp_parse(netdissect_options *ndo, const u_char *bp, int length)
 {
     u_char op;
     int ret_len;
@@ -272,22 +272,22 @@ trunc:
 }
 
 static int
-resp_print_simple_string(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_simple_string(netdissect_options *ndo, const u_char *bp, int length) {
     return resp_print_string_error_integer(ndo, bp, length);
 }
 
 static int
-resp_print_integer(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_integer(netdissect_options *ndo, const u_char *bp, int length) {
     return resp_print_string_error_integer(ndo, bp, length);
 }
 
 static int
-resp_print_error(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_error(netdissect_options *ndo, const u_char *bp, int length) {
     return resp_print_string_error_integer(ndo, bp, length);
 }
 
 static int
-resp_print_string_error_integer(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_string_error_integer(netdissect_options *ndo, const u_char *bp, int length) {
     int length_cur = length, len, ret_len;
     const u_char *bp_ptr;
 
@@ -322,7 +322,7 @@ trunc:
 }
 
 static int
-resp_print_bulk_string(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_bulk_string(netdissect_options *ndo, const u_char *bp, int length) {
     int length_cur = length, string_len;
 
     /* bp points to the op; skip it */
@@ -368,7 +368,7 @@ trunc:
 }
 
 static int
-resp_print_bulk_array(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_bulk_array(netdissect_options *ndo, const u_char *bp, int length) {
     u_int length_cur = length;
     int array_len, i, ret_len;
 
@@ -407,7 +407,7 @@ trunc:
 }
 
 static int
-resp_print_inline(netdissect_options *ndo, register const u_char *bp, int length) {
+resp_print_inline(netdissect_options *ndo, const u_char *bp, int length) {
     int length_cur = length;
     int len;
     const u_char *bp_ptr;
@@ -454,7 +454,7 @@ trunc:
 }
 
 static int
-resp_get_length(netdissect_options *ndo, register const u_char *bp, int len, const u_char **endp)
+resp_get_length(netdissect_options *ndo, const u_char *bp, int len, const u_char **endp)
 {
     int result;
     u_char c;
index 4bc070952bd1cba850451ddff546196647752e72..eebb3ff04025e11805a1a8486080c8627cce21ef 100644 (file)
@@ -95,9 +95,9 @@ struct rip_netinfo {
 
 static void
 rip_entry_print_v1(netdissect_options *ndo,
-                   register const struct rip_netinfo *ni)
+                   const struct rip_netinfo *ni)
 {
-       register u_short family;
+       u_short family;
 
        /* RFC 1058 */
        family = EXTRACT_BE_U_2(&ni->rip_family);
@@ -126,15 +126,15 @@ rip_entry_print_v1(netdissect_options *ndo,
 
 static unsigned
 rip_entry_print_v2(netdissect_options *ndo,
-                   register const struct rip_netinfo *ni, const unsigned remaining)
+                   const struct rip_netinfo *ni, const unsigned remaining)
 {
-       register u_short family;
+       u_short family;
 
        family = EXTRACT_BE_U_2(&ni->rip_family);
        if (family == 0xFFFF) { /* variable-sized authentication structures */
                uint16_t auth_type = EXTRACT_BE_U_2(&ni->rip_tag);
                if (auth_type == 2) {
-                       register const u_char *p = (const u_char *)&ni->rip_dest;
+                       const u_char *p = (const u_char *)&ni->rip_dest;
                        u_int i = 0;
                        ND_PRINT((ndo, "\n\t  Simple Text Authentication data: "));
                        for (; i < RIP_AUTHLEN; p++, i++)
@@ -179,9 +179,9 @@ void
 rip_print(netdissect_options *ndo,
           const u_char *dat, u_int length)
 {
-       register const struct rip *rp;
-       register const struct rip_netinfo *ni;
-       register u_int i, j;
+       const struct rip *rp;
+       const struct rip_netinfo *ni;
+       u_int i, j;
 
        if (ndo->ndo_snapend < dat) {
                ND_PRINT((ndo, " %s", tstr));
index 1939893189643b3511df3076987e12b74f4f3e3e..daf7bd3751d7ea0d28279f3f0871c015d4784afe 100644 (file)
@@ -94,7 +94,7 @@ static int IN6_IS_ADDR_UNSPECIFIED(const struct in6_addr *addr)
 #endif
 
 static int
-rip6_entry_print(netdissect_options *ndo, register const struct netinfo6 *ni, int metric)
+rip6_entry_print(netdissect_options *ndo, const struct netinfo6 *ni, int metric)
 {
        int l;
        l = ND_PRINT((ndo, "%s/%d", ip6addr_string(ndo, &ni->rip6_dest), ni->rip6_plen));
@@ -108,8 +108,8 @@ rip6_entry_print(netdissect_options *ndo, register const struct netinfo6 *ni, in
 void
 ripng_print(netdissect_options *ndo, const u_char *dat, unsigned int length)
 {
-       register const struct rip6 *rp = (const struct rip6 *)dat;
-       register const struct netinfo6 *ni;
+       const struct rip6 *rp = (const struct rip6 *)dat;
+       const struct netinfo6 *ni;
        unsigned int length_left;
        u_int j;
 
index 47a131146929da514428a65d388f0e2f59eb3ef9..45e2787d3ef12991757f5eedb13f8ddd09870109 100644 (file)
@@ -386,7 +386,7 @@ trunc:
 }
 
 void
-rpki_rtr_print(netdissect_options *ndo, register const u_char *pptr, register u_int len)
+rpki_rtr_print(netdissect_options *ndo, const u_char *pptr, u_int len)
 {
     if (!ndo->ndo_vflag) {
        ND_PRINT((ndo, ", RPKI-RTR"));
index ecfa3740bf9546b829280967747cb53aedb554e1..0885f64657c8ca30be51dbf403a98197d69ee228 100644 (file)
@@ -88,7 +88,7 @@ static const struct tok opcode_values[] = {
  */
 void
 rrcp_print(netdissect_options *ndo,
-         register const u_char *cp,
+         const u_char *cp,
          u_int length _U_,
          const struct lladdr_info *src,
          const struct lladdr_info *dst)
index dfedaf50375725935bfbfc3dfcaf2048bb147618..29d2741299117796967d1e99647eb59beb3ae22f 100644 (file)
@@ -1849,7 +1849,7 @@ trunc:
 
 void
 rsvp_print(netdissect_options *ndo,
-           register const u_char *pptr, register u_int len)
+           const u_char *pptr, u_int len)
 {
     const struct rsvp_common_header *rsvp_com_header;
     const u_char *tptr;
index 66c417586a9b1fd636b0e0902d1d1ec30488e050..269496aaecfc98ccfd107b626e4cf83be2a03a95 100644 (file)
 #include "ip6.h"
 
 int
-rt6_print(netdissect_options *ndo, register const u_char *bp, const u_char *bp2 _U_)
+rt6_print(netdissect_options *ndo, const u_char *bp, const u_char *bp2 _U_)
 {
-       register const struct ip6_rthdr *dp;
-       register const struct ip6_rthdr0 *dp0;
-       register const u_char *ep;
+       const struct ip6_rthdr *dp;
+       const struct ip6_rthdr0 *dp0;
+       const u_char *ep;
        u_int i, len, type;
-       register const struct in6_addr *addr;
+       const struct in6_addr *addr;
 
        dp = (const struct ip6_rthdr *)bp;
 
index 2f5ac014eab287c178a51c4f8e381633dbc35e2f..d4ca5094b06ce6d2178c2acd68e590ccbc1aba73 100644 (file)
@@ -526,10 +526,10 @@ static int is_ubik(uint32_t);
 
 void
 rx_print(netdissect_options *ndo,
-         register const u_char *bp, u_int length, u_int sport, u_int dport,
+         const u_char *bp, u_int length, u_int sport, u_int dport,
          const u_char *bp2)
 {
-       register const struct rx_header *rxh;
+       const struct rx_header *rxh;
        uint32_t i;
        uint8_t type, flags;
        uint32_t opcode;
@@ -889,7 +889,7 @@ rx_cache_find(const struct rx_header *rxh, const struct ip *ip, u_int sport,
 
 static void
 fs_print(netdissect_options *ndo,
-         register const u_char *bp, u_int length)
+         const u_char *bp, u_int length)
 {
        uint32_t fs_op;
        uint32_t i;
@@ -1059,7 +1059,7 @@ trunc:
 
 static void
 fs_reply_print(netdissect_options *ndo,
-               register const u_char *bp, u_int length, uint32_t opcode)
+               const u_char *bp, u_int length, uint32_t opcode)
 {
        uint32_t i;
        const struct rx_header *rxh;
@@ -1224,7 +1224,7 @@ finish:
 
 static void
 cb_print(netdissect_options *ndo,
-         register const u_char *bp, u_int length)
+         const u_char *bp, u_int length)
 {
        uint32_t cb_op;
        uint32_t i;
@@ -1305,7 +1305,7 @@ trunc:
 
 static void
 cb_reply_print(netdissect_options *ndo,
-               register const u_char *bp, u_int length, uint32_t opcode)
+               const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -1357,7 +1357,7 @@ trunc:
 
 static void
 prot_print(netdissect_options *ndo,
-           register const u_char *bp, u_int length)
+           const u_char *bp, u_int length)
 {
        uint32_t i;
        uint32_t pt_op;
@@ -1498,7 +1498,7 @@ trunc:
 
 static void
 prot_reply_print(netdissect_options *ndo,
-                 register const u_char *bp, u_int length, uint32_t opcode)
+                 const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -1613,7 +1613,7 @@ trunc:
 
 static void
 vldb_print(netdissect_options *ndo,
-           register const u_char *bp, u_int length)
+           const u_char *bp, u_int length)
 {
        uint32_t vldb_op;
        uint32_t i;
@@ -1704,7 +1704,7 @@ trunc:
 
 static void
 vldb_reply_print(netdissect_options *ndo,
-                 register const u_char *bp, u_int length, uint32_t opcode)
+                 const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -1894,7 +1894,7 @@ trunc:
 
 static void
 kauth_print(netdissect_options *ndo,
-            register const u_char *bp, u_int length)
+            const u_char *bp, u_int length)
 {
        uint32_t kauth_op;
 
@@ -1985,7 +1985,7 @@ trunc:
 
 static void
 kauth_reply_print(netdissect_options *ndo,
-                  register const u_char *bp, u_int length, uint32_t opcode)
+                  const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -2039,7 +2039,7 @@ trunc:
 
 static void
 vol_print(netdissect_options *ndo,
-          register const u_char *bp, u_int length)
+          const u_char *bp, u_int length)
 {
        uint32_t vol_op;
 
@@ -2238,7 +2238,7 @@ trunc:
 
 static void
 vol_reply_print(netdissect_options *ndo,
-                register const u_char *bp, u_int length, uint32_t opcode)
+                const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -2375,7 +2375,7 @@ trunc:
 
 static void
 bos_print(netdissect_options *ndo,
-          register const u_char *bp, u_int length)
+          const u_char *bp, u_int length)
 {
        uint32_t bos_op;
 
@@ -2464,7 +2464,7 @@ trunc:
 
 static void
 bos_reply_print(netdissect_options *ndo,
-                register const u_char *bp, u_int length, uint32_t opcode)
+                const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -2525,7 +2525,7 @@ is_ubik(uint32_t opcode)
 
 static void
 ubik_print(netdissect_options *ndo,
-           register const u_char *bp)
+           const u_char *bp)
 {
        uint32_t ubik_op;
        uint32_t temp;
@@ -2640,7 +2640,7 @@ trunc:
 
 static void
 ubik_reply_print(netdissect_options *ndo,
-                 register const u_char *bp, u_int length, uint32_t opcode)
+                 const u_char *bp, u_int length, uint32_t opcode)
 {
        const struct rx_header *rxh;
        uint8_t type;
@@ -2706,7 +2706,7 @@ trunc:
 
 static void
 rx_ack_print(netdissect_options *ndo,
-             register const u_char *bp, u_int length)
+             const u_char *bp, u_int length)
 {
        const struct rx_ackPacket *rxa;
        uint8_t nAcks;
index 91fa98cb032ae366712c11dc5b3777c4a16320b5..1805904133f7ad7acdc80ac25036f8d8af180efe 100644 (file)
@@ -59,9 +59,9 @@ u_int
 sl_if_print(netdissect_options *ndo,
             const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int caplen = h->caplen;
-       register u_int length = h->len;
-       register const struct ip *ip;
+       u_int caplen = h->caplen;
+       u_int length = h->len;
+       const struct ip *ip;
 
        if (caplen < SLIP_HDRLEN || length < SLIP_HDRLEN) {
                ND_PRINT((ndo, "%s", tstr));
@@ -99,9 +99,9 @@ u_int
 sl_bsdos_if_print(netdissect_options *ndo,
                   const struct pcap_pkthdr *h, const u_char *p)
 {
-       register u_int caplen = h->caplen;
-       register u_int length = h->len;
-       register const struct ip *ip;
+       u_int caplen = h->caplen;
+       u_int length = h->len;
+       const struct ip *ip;
 
        if (caplen < SLIP_HDRLEN) {
                ND_PRINT((ndo, "%s", tstr));
@@ -124,8 +124,8 @@ sl_bsdos_if_print(netdissect_options *ndo,
 
 static void
 sliplink_print(netdissect_options *ndo,
-               register const u_char *p, register const struct ip *ip,
-               register u_int length)
+               const u_char *p, const struct ip *ip,
+               u_int length)
 {
        int dir;
        u_int hlen;
@@ -148,7 +148,7 @@ sliplink_print(netdissect_options *ndo,
        }
        if (ndo->ndo_nflag) {
                /* XXX just dump the header */
-               register int i;
+               int i;
 
                for (i = SLX_CHDR; i < SLX_CHDR + CHDR_LEN - 1; ++i)
                        ND_PRINT((ndo, "%02x.", EXTRACT_U_1(p + i)));
@@ -194,9 +194,9 @@ sliplink_print(netdissect_options *ndo,
 
 static const u_char *
 print_sl_change(netdissect_options *ndo,
-                const char *str, register const u_char *cp)
+                const char *str, const u_char *cp)
 {
-       register u_int i;
+       u_int i;
 
        if ((i = EXTRACT_U_1(cp)) == 0) {
                cp++;
@@ -209,9 +209,9 @@ print_sl_change(netdissect_options *ndo,
 
 static const u_char *
 print_sl_winchange(netdissect_options *ndo,
-                   register const u_char *cp)
+                   const u_char *cp)
 {
-       register short i;
+       short i;
 
        if ((i = EXTRACT_U_1(cp)) == 0) {
                cp++;
@@ -230,8 +230,8 @@ compressed_sl_print(netdissect_options *ndo,
                     const u_char *chdr, const struct ip *ip,
                     u_int length, int dir)
 {
-       register const u_char *cp = chdr;
-       register u_int flags, hlen;
+       const u_char *cp = chdr;
+       u_int flags, hlen;
 
        flags = EXTRACT_U_1(cp);
        cp++;
index 53ee4e96e1fd182b24f5a275d8228307dcb48513..0f0a2e7f534e86e79087ded03583dcf72ccd85e2 100644 (file)
@@ -130,7 +130,7 @@ static const struct tok sll_pkttype_values[] = {
 };
 
 static inline void
-sll_print(netdissect_options *ndo, register const struct sll_header *sllp, u_int length)
+sll_print(netdissect_options *ndo, const struct sll_header *sllp, u_int length)
 {
        u_short ether_type;
 
@@ -195,7 +195,7 @@ sll_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char
 {
        u_int caplen = h->caplen;
        u_int length = h->len;
-       register const struct sll_header *sllp;
+       const struct sll_header *sllp;
        u_short ether_type;
        int llc_hdrlen;
        u_int hdrlen;
index c6b6bd7c8e3241d14b536dffc156d1bd1dbee5c3..57fa595aa312f4cf429bd913747f0ae7e3716c91 100644 (file)
@@ -237,12 +237,12 @@ struct lacp_marker_tlv_terminator_t {
     uint8_t pad[50];
 };
 
-static void slow_marker_lacp_print(netdissect_options *, register const u_char *, register u_int, u_int);
-static void slow_oam_print(netdissect_options *, register const u_char *, register u_int);
+static void slow_marker_lacp_print(netdissect_options *, const u_char *, u_int, u_int);
+static void slow_oam_print(netdissect_options *, const u_char *, u_int);
 
 void
 slow_print(netdissect_options *ndo,
-           register const u_char *pptr, register u_int len)
+           const u_char *pptr, u_int len)
 {
     int print_version;
     u_int subtype;
@@ -346,7 +346,7 @@ trunc:
 
 static void
 slow_marker_lacp_print(netdissect_options *ndo,
-                       register const u_char *tptr, register u_int tlen,
+                       const u_char *tptr, u_int tlen,
                        u_int proto_subtype)
 {
     const struct tlv_header_t *tlv_header;
@@ -487,7 +487,7 @@ trunc:
 
 static void
 slow_oam_print(netdissect_options *ndo,
-               register const u_char *tptr, register u_int tlen)
+               const u_char *tptr, u_int tlen)
 {
     uint8_t code;
     uint8_t type, length;
index 1fdd5bf8d8bda2e67627ae45a5dacc88b0e2fec7..976264c693db8514f28bc279655e23c9f6d5afa6 100644 (file)
@@ -418,7 +418,7 @@ static const char *SnmpVersion[] = {
  */
 static int
 asn1_parse(netdissect_options *ndo,
-           register const u_char *p, u_int len, struct be *elem)
+           const u_char *p, u_int len, struct be *elem)
 {
        u_char form, class, id;
        int i, hdr;
@@ -535,7 +535,7 @@ asn1_parse(netdissect_options *ndo,
                                break;
 
                        case INTEGER: {
-                               register int32_t data;
+                               int32_t data;
                                elem->type = BE_INT;
                                data = 0;
 
@@ -579,7 +579,7 @@ asn1_parse(netdissect_options *ndo,
                        case COUNTER:
                        case GAUGE:
                        case TIMETICKS: {
-                               register uint32_t data;
+                               uint32_t data;
                                elem->type = BE_UNS;
                                data = 0;
                                for (i = elem->asnlen; i-- > 0; p++)
@@ -589,7 +589,7 @@ asn1_parse(netdissect_options *ndo,
                        }
 
                        case COUNTER64: {
-                               register uint64_t data64;
+                               uint64_t data64;
                                elem->type = BE_UNS64;
                                data64 = 0;
                                for (i = elem->asnlen; i-- > 0; p++)
@@ -693,7 +693,7 @@ trunc:
 static int
 asn1_print_string(netdissect_options *ndo, struct be *elem)
 {
-       register int printable = 1, first = 1;
+       int printable = 1, first = 1;
        const u_char *p;
        uint32_t asnlen = elem->asnlen;
        uint32_t i;
index ce8b039348b5a1fc39dbb1b1b8c79d161f26a35a..239742bcc56786a083ef52ac38352463b02f7a65 100644 (file)
@@ -165,12 +165,12 @@ static const struct tok proc2str[] = {
 static char *progstr(uint32_t);
 
 void
-sunrpc_print(netdissect_options *ndo, register const u_char *bp,
-                    register u_int length, register const u_char *bp2)
+sunrpc_print(netdissect_options *ndo, const u_char *bp,
+                    u_int length, const u_char *bp2)
 {
-       register const struct sunrpc_msg *rp;
-       register const struct ip *ip;
-       register const struct ip6_hdr *ip6;
+       const struct sunrpc_msg *rp;
+       const struct ip *ip;
+       const struct ip6_hdr *ip6;
        uint32_t x;
        char srcid[20], dstid[20];      /*fits 32bit*/
 
@@ -230,7 +230,7 @@ static char *
 progstr(uint32_t prog)
 {
 #if defined(HAVE_GETRPCBYNUMBER) && defined(HAVE_RPC_RPC_H)
-       register struct rpcent *rp;
+       struct rpcent *rp;
 #endif
        static char buf[32];
        static uint32_t lastprog = 0;
index 56f7fc260f40360a9f4617671bb0d07c02372866..e80bd45c626673af5fc661f789558b6425914042 100644 (file)
@@ -38,9 +38,9 @@ struct symantec_header {
 };
 
 static inline void
-symantec_hdr_print(netdissect_options *ndo, register const u_char *bp, u_int length)
+symantec_hdr_print(netdissect_options *ndo, const u_char *bp, u_int length)
 {
-       register const struct symantec_header *sp;
+       const struct symantec_header *sp;
        uint16_t etype;
 
        sp = (const struct symantec_header *)bp;
index 1610bd6d594e03c6b0738a04e258d7f672d4bb3c..901c6f3a652c91667a6be0d202a108e8f1ba5e5b 100644 (file)
@@ -78,7 +78,7 @@ static const struct tok syslog_facility_values[] = {
 
 void
 syslog_print(netdissect_options *ndo,
-             register const u_char *pptr, register u_int len)
+             const u_char *pptr, u_int len)
 {
     uint16_t msg_off = 0;
     uint16_t pri = 0;
index 70af9b613e60a82bcacae9767f2a74f4b622cea4..9e449fe456d2b2eff8b736f2b74978c1409a1477 100644 (file)
@@ -60,8 +60,8 @@ static int tcp_verify_signature(netdissect_options *ndo,
                                 const u_char *data, int length, const u_char *rcvsig);
 #endif
 
-static void print_tcp_rst_data(netdissect_options *, register const u_char *sp, u_int length);
-static void print_tcp_fastopen_option(netdissect_options *ndo, register const u_char *cp,
+static void print_tcp_rst_data(netdissect_options *, const u_char *sp, u_int length);
+static void print_tcp_fastopen_option(netdissect_options *ndo, const u_char *cp,
                                       u_int datalen, int exp);
 
 #define MAX_RST_DATA_LEN       30
@@ -138,9 +138,9 @@ static const struct tok tcp_option_values[] = {
 
 static int
 tcp_cksum(netdissect_options *ndo,
-          register const struct ip *ip,
-          register const struct tcphdr *tp,
-          register u_int len)
+          const struct ip *ip,
+          const struct tcphdr *tp,
+          u_int len)
 {
        return nextproto4_cksum(ndo, ip, (const uint8_t *)tp, len, len,
                                IPPROTO_TCP);
@@ -148,9 +148,9 @@ tcp_cksum(netdissect_options *ndo,
 
 static int
 tcp6_cksum(netdissect_options *ndo,
-           register const struct ip6_hdr *ip6,
-           register const struct tcphdr *tp,
-           register u_int len)
+           const struct ip6_hdr *ip6,
+           const struct tcphdr *tp,
+           u_int len)
 {
        return nextproto6_cksum(ndo, ip6, (const uint8_t *)tp, len, len,
                                IPPROTO_TCP);
@@ -158,20 +158,20 @@ tcp6_cksum(netdissect_options *ndo,
 
 void
 tcp_print(netdissect_options *ndo,
-          register const u_char *bp, register u_int length,
-          register const u_char *bp2, int fragmented)
+          const u_char *bp, u_int length,
+          const u_char *bp2, int fragmented)
 {
-        register const struct tcphdr *tp;
-        register const struct ip *ip;
-        register u_char flags;
-        register u_int hlen;
-        register char ch;
+        const struct tcphdr *tp;
+        const struct ip *ip;
+        u_char flags;
+        u_int hlen;
+        char ch;
         uint16_t sport, dport, win, urp;
         uint32_t seq, ack, thseq, thack;
         u_int utoval;
         uint16_t magic;
-        register int rev;
-        register const struct ip6_hdr *ip6;
+        int rev;
+        const struct ip6_hdr *ip6;
 
         tp = (const struct tcphdr *)bp;
         ip = (const struct ip *)bp2;
@@ -250,7 +250,7 @@ tcp_print(netdissect_options *ndo,
                  */
                 rev = 0;
                 if (ip6) {
-                        register struct tcp_seq_hash6 *th;
+                        struct tcp_seq_hash6 *th;
                         struct tcp_seq_hash6 *tcp_seq_hash;
                         const void *src, *dst;
                         struct tha6 tha;
@@ -304,7 +304,7 @@ tcp_print(netdissect_options *ndo,
                         thseq = th->seq;
                         thack = th->ack;
                 } else {
-                        register struct tcp_seq_hash *th;
+                        struct tcp_seq_hash *th;
                         struct tcp_seq_hash *tcp_seq_hash;
                         struct tha tha;
 
@@ -418,9 +418,9 @@ tcp_print(netdissect_options *ndo,
          * Handle any options.
          */
         if (hlen > sizeof(*tp)) {
-                register const u_char *cp;
-                register u_int i, opt, datalen;
-                register u_int len;
+                const u_char *cp;
+                u_int i, opt, datalen;
+                u_int len;
 
                 hlen -= sizeof(*tp);
                 cp = (const u_char *)tp + sizeof(*tp);
@@ -741,7 +741,7 @@ tcp_print(netdissect_options *ndo,
                  * to NFS print routines.
                  */
                 uint32_t fraglen;
-                register const struct sunrpc_msg *rp;
+                const struct sunrpc_msg *rp;
                 enum sunrpc_msg_type direction;
 
                 fraglen = EXTRACT_BE_U_4(bp) & 0x7FFFFFFF;
@@ -792,7 +792,7 @@ tcp_print(netdissect_options *ndo,
 
 static void
 print_tcp_rst_data(netdissect_options *ndo,
-                   register const u_char *sp, u_int length)
+                   const u_char *sp, u_int length)
 {
         int c;
 
@@ -811,7 +811,7 @@ print_tcp_rst_data(netdissect_options *ndo,
 }
 
 static void
-print_tcp_fastopen_option(netdissect_options *ndo, register const u_char *cp,
+print_tcp_fastopen_option(netdissect_options *ndo, const u_char *cp,
                           u_int datalen, int exp)
 {
         u_int i;
index 5ebf93335cee0796e059056b9252ddc026a527ff..e0bedc3918b7202b0b07e0a54a37d8b4b5d98078 100644 (file)
@@ -89,10 +89,10 @@ static const struct tok err2str[] = {
  */
 void
 tftp_print(netdissect_options *ndo,
-           register const u_char *bp, u_int length)
+           const u_char *bp, u_int length)
 {
-       register const char *cp;
-       register int opcode;
+       const char *cp;
+       int opcode;
        u_int ui;
 
        /* Print length */
index 33397c0d20de9ac8e5d6e07c8da6d41458d7cba7..34eb61683744f87ababaabc584adc401413487ec 100644 (file)
@@ -96,7 +96,7 @@ static const char *tsptype[TSPTYPENUMBER] =
 
 void
 timed_print(netdissect_options *ndo,
-            register const u_char *bp)
+            const u_char *bp)
 {
        const struct tsp *tsp = (const struct tsp *)bp;
        long sec, usec;
index 5cca3b072ca443f79dbddcb413af99f36f7ca3ed..ff2a38415a601fc2c6d9638795faa045c8c9c4c3 100644 (file)
@@ -104,8 +104,8 @@ extract_token_addrs(const struct token_header *trp, char *fsrc, char *fdst)
  */
 static inline void
 token_hdr_print(netdissect_options *ndo,
-                register const struct token_header *trp, register u_int length,
-                register const u_char *fsrc, register const u_char *fdst)
+                const struct token_header *trp, u_int length,
+                const u_char *fsrc, const u_char *fdst)
 {
        const char *srcname, *dstname;
 
index c58339e99d3067da884f377f7a2a5130be78c2cc..7fe4b9de6799b74b14f6faa79ca0f0ab2468d827 100644 (file)
@@ -97,7 +97,7 @@ struct rtcp_rr {
 #define RTCP_PT_APP    204
 
 static void
-vat_print(netdissect_options *ndo, const void *hdr, register const struct udphdr *up)
+vat_print(netdissect_options *ndo, const void *hdr, const struct udphdr *up)
 {
        /* vat/vt audio */
        u_int ts;
@@ -136,7 +136,7 @@ trunc:
 
 static void
 rtp_print(netdissect_options *ndo, const void *hdr, u_int len,
-          register const struct udphdr *up)
+          const struct udphdr *up)
 {
        /* rtp v1 or v2 */
        const u_int *ip = (const u_int *)hdr;
@@ -298,9 +298,9 @@ trunc:
        return ep;
 }
 
-static int udp_cksum(netdissect_options *ndo, register const struct ip *ip,
-                    register const struct udphdr *up,
-                    register u_int len)
+static int udp_cksum(netdissect_options *ndo, const struct ip *ip,
+                    const struct udphdr *up,
+                    u_int len)
 {
        return nextproto4_cksum(ndo, ip, (const uint8_t *)(const void *)up, len, len,
                                IPPROTO_UDP);
@@ -367,15 +367,15 @@ udpipaddr_print(netdissect_options *ndo, const struct ip *ip, int sport, int dpo
 }
 
 void
-udp_print(netdissect_options *ndo, register const u_char *bp, u_int length,
-         register const u_char *bp2, int fragmented)
+udp_print(netdissect_options *ndo, const u_char *bp, u_int length,
+         const u_char *bp2, int fragmented)
 {
-       register const struct udphdr *up;
-       register const struct ip *ip;
-       register const u_char *cp;
-       register const u_char *ep = bp + length;
+       const struct udphdr *up;
+       const struct ip *ip;
+       const u_char *cp;
+       const u_char *ep = bp + length;
        uint16_t sport, dport, ulen;
-       register const struct ip6_hdr *ip6;
+       const struct ip6_hdr *ip6;
 
        if (ep > ndo->ndo_snapend)
                ep = ndo->ndo_snapend;
@@ -420,7 +420,7 @@ udp_print(netdissect_options *ndo, register const u_char *bp, u_int length,
        }
 
        if (ndo->ndo_packettype) {
-               register const struct sunrpc_msg *rp;
+               const struct sunrpc_msg *rp;
                enum sunrpc_msg_type direction;
 
                switch (ndo->ndo_packettype) {
@@ -503,7 +503,7 @@ udp_print(netdissect_options *ndo, register const u_char *bp, u_int length,
 
        udpipaddr_print(ndo, ip, sport, dport);
        if (!ndo->ndo_qflag) {
-               register const struct sunrpc_msg *rp;
+               const struct sunrpc_msg *rp;
                enum sunrpc_msg_type direction;
 
                rp = (const struct sunrpc_msg *)(up + 1);
index 04862881b5cd22ad0ae3c317b3415b9623290e9f..5e425f16c02a7d2690191b2ea5f68fcf6a7bb654 100644 (file)
@@ -136,7 +136,7 @@ usb_header_print(netdissect_options *ndo, const pcap_usb_header *uh)
  */
 u_int
 usb_linux_48_byte_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h,
-                           register const u_char *p)
+                           const u_char *p)
 {
        if (h->caplen < sizeof(pcap_usb_header)) {
                ND_PRINT((ndo, "%s", tstr));
@@ -159,7 +159,7 @@ usb_linux_48_byte_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h,
  */
 u_int
 usb_linux_64_byte_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h,
-                           register const u_char *p)
+                           const u_char *p)
 {
        if (h->caplen < sizeof(pcap_usb_header_mmapped)) {
                ND_PRINT((ndo, "%s", tstr));
index 5cccd73fa1a48307dabd113e86fdd7cec1821d44..0743cfa0d28f46d745642106b14a70c5329fe892 100644 (file)
@@ -84,7 +84,7 @@
  * to the packet capture mechanism.
  */
 int
-vjc_print(netdissect_options *ndo, register const u_char *bp, u_short proto _U_)
+vjc_print(netdissect_options *ndo, const u_char *bp, u_short proto _U_)
 {
        int i;
 
index 5dd9939bcb969e42a14f0eea9d2612b56223c962..ebc25fc9b755d1ed3a0e9de6b56cc604c1a6a009 100644 (file)
@@ -97,7 +97,7 @@ static const struct tok vqp_obj_values[] = {
 };
 
 void
-vqp_print(netdissect_options *ndo, register const u_char *pptr, register u_int len)
+vqp_print(netdissect_options *ndo, const u_char *pptr, u_int len)
 {
     const struct vqp_common_header_t *vqp_common_header;
     const struct vqp_obj_tlv_t *vqp_obj_tlv;
index d9aa4b815c03760e0ffa93f8a1c7e9fdf5409a77..b7e309d00a5fee79c0bb3920f2ff1435398ae12c 100644 (file)
@@ -104,8 +104,8 @@ static const struct tok auth2str[] = {
 
 void
 vrrp_print(netdissect_options *ndo,
-           register const u_char *bp, register u_int len,
-           register const u_char *bp2, int ttl)
+           const u_char *bp, u_int len,
+           const u_char *bp2, int ttl)
 {
        int version, type, auth_type = VRRP_AUTH_NONE; /* keep compiler happy */
        const char *type_s;
index 7be80266794ca609138d53b7a65dccf2980b3a92..7eddf754eefd33c5161b36717a0b25a7a4aec7d0 100644 (file)
@@ -396,9 +396,9 @@ wb_drawop(netdissect_options *ndo,
  */
 void
 wb_print(netdissect_options *ndo,
-         register const void *hdr, register u_int len)
+         const void *hdr, u_int len)
 {
-       register const struct pkt_hdr *ph;
+       const struct pkt_hdr *ph;
 
        ph = (const struct pkt_hdr *)hdr;
        if (len < sizeof(*ph) || !ND_TTEST(*ph)) {
index 70c9fb375c92cd27809bb62f272955754e61e7ea..84f30f2d41c570694fc194551735f635fc4e57aa 100644 (file)
--- a/tcpdump.c
+++ b/tcpdump.c
@@ -929,10 +929,10 @@ set_dumper_capsicum_rights(pcap_dumper_t *p)
  * Copy arg vector into a new buffer, concatenating arguments with spaces.
  */
 static char *
-copy_argv(register char **argv)
+copy_argv(char **argv)
 {
-       register char **p;
-       register u_int len = 0;
+       char **p;
+       u_int len = 0;
        char *buf;
        char *src, *dst;
 
@@ -972,8 +972,8 @@ copy_argv(register char **argv)
 static char *
 read_infile(char *fname)
 {
-       register int i, fd, cc;
-       register char *cp;
+       int i, fd, cc;
+       char *cp;
        struct stat buf;
 
        fd = open(fname, O_RDONLY|O_BINARY);
@@ -1282,10 +1282,10 @@ fprintf(stderr, "Opening %s\n", device);
 int
 main(int argc, char **argv)
 {
-       register int cnt, op, i;
+       int cnt, op, i;
        bpf_u_int32 localnet = 0, netmask = 0;
        int timezone_offset = 0;
-       register char *cp, *infile, *cmdbuf, *device, *RFileName, *VFileName, *WFileName;
+       char *cp, *infile, *cmdbuf, *device, *RFileName, *VFileName, *WFileName;
        char *endp;
        pcap_handler callback;
        int dlt;
@@ -2471,7 +2471,7 @@ child_cleanup(int signo _U_)
 #endif /* HAVE_FORK && HAVE_VFORK */
 
 static void
-info(register int verbose)
+info(int verbose)
 {
        struct pcap_stat stats;
 
index 13191e9c160398c795d42530fded1feadc1dc8d1..4ac4bc49269a11e4bb15d68bd735f6ecabd0db33 100644 (file)
@@ -94,10 +94,10 @@ fn_print_char(netdissect_options *ndo, u_char c)
  */
 int
 fn_print(netdissect_options *ndo,
-         register const u_char *s, register const u_char *ep)
+         const u_char *s, const u_char *ep)
 {
-       register int ret;
-       register u_char c;
+       int ret;
+       u_char c;
 
        ret = 1;                        /* assume truncated */
        while (ep == NULL || s < ep) {
@@ -128,10 +128,10 @@ fn_print(netdissect_options *ndo,
  */
 u_int
 fn_printztn(netdissect_options *ndo,
-         register const u_char *s, register u_int n, register const u_char *ep)
+         const u_char *s, u_int n, const u_char *ep)
 {
-       register u_int bytes;
-       register u_char c;
+       u_int bytes;
+       u_char c;
 
        bytes = 0;
        for (;;) {
@@ -177,9 +177,9 @@ fn_printztn(netdissect_options *ndo,
  */
 int
 fn_printn(netdissect_options *ndo,
-          register const u_char *s, register u_int n, register const u_char *ep)
+          const u_char *s, u_int n, const u_char *ep)
 {
-       register u_char c;
+       u_char c;
 
        while (n > 0 && (ep == NULL || s < ep)) {
                n--;
@@ -206,11 +206,11 @@ fn_printn(netdissect_options *ndo,
  */
 int
 fn_printzp(netdissect_options *ndo,
-           register const u_char *s, register u_int n,
-           register const u_char *ep)
+           const u_char *s, u_int n,
+           const u_char *ep)
 {
-       register int ret;
-       register u_char c;
+       int ret;
+       u_char c;
 
        ret = 1;                        /* assume truncated */
        while (n > 0 && (ep == NULL || s < ep)) {
@@ -312,9 +312,9 @@ _U_
  */
 void
 ts_print(netdissect_options *ndo,
-         register const struct timeval *tvp)
+         const struct timeval *tvp)
 {
-       register int s;
+       int s;
        struct tm *tm;
        time_t Time;
        char buf[TS_BUF_SIZE];
@@ -480,8 +480,8 @@ print_unknown_data(netdissect_options *ndo, const u_char *cp,const char *ident,i
  * Convert a token value to a string; use "fmt" if not found.
  */
 const char *
-tok2strbuf(register const struct tok *lp, register const char *fmt,
-          register u_int v, char *buf, size_t bufsize)
+tok2strbuf(const struct tok *lp, const char *fmt,
+          u_int v, char *buf, size_t bufsize)
 {
        if (lp != NULL) {
                while (lp->s != NULL) {
@@ -503,8 +503,8 @@ tok2strbuf(register const struct tok *lp, register const char *fmt,
  * in round-robin fashion.
  */
 const char *
-tok2str(register const struct tok *lp, register const char *fmt,
-       register u_int v)
+tok2str(const struct tok *lp, const char *fmt,
+       u_int v)
 {
        static char buf[4][TOKBUFSIZE];
        static int idx = 0;
@@ -521,14 +521,14 @@ tok2str(register const struct tok *lp, register const char *fmt,
  * if the s field is positive.
  */
 static char *
-bittok2str_internal(register const struct tok *lp, register const char *fmt,
-          register u_int v, const char *sep)
+bittok2str_internal(const struct tok *lp, const char *fmt,
+          u_int v, const char *sep)
 {
         static char buf[1024+1]; /* our string buffer */
         char *bufp = buf;
         size_t space_left = sizeof(buf), string_size;
-        register u_int rotbit; /* this is the bit we rotate through all bitpositions */
-        register u_int tokval;
+        u_int rotbit; /* this is the bit we rotate through all bitpositions */
+        u_int tokval;
         const char * sepstr = "";
 
        while (lp != NULL && lp->s != NULL) {
@@ -574,8 +574,8 @@ bittok2str_internal(register const struct tok *lp, register const char *fmt,
  * this is useful for parsing bitfields, the output strings are not seperated.
  */
 char *
-bittok2str_nosep(register const struct tok *lp, register const char *fmt,
-          register u_int v)
+bittok2str_nosep(const struct tok *lp, const char *fmt,
+          u_int v)
 {
     return (bittok2str_internal(lp, fmt, v, ""));
 }
@@ -585,8 +585,8 @@ bittok2str_nosep(register const struct tok *lp, register const char *fmt,
  * this is useful for parsing bitfields, the output strings are comma seperated.
  */
 char *
-bittok2str(register const struct tok *lp, register const char *fmt,
-          register u_int v)
+bittok2str(const struct tok *lp, const char *fmt,
+          u_int v)
 {
     return (bittok2str_internal(lp, fmt, v, ", "));
 }
@@ -598,8 +598,8 @@ bittok2str(register const struct tok *lp, register const char *fmt,
  * correct for bounds-checking.
  */
 const char *
-tok2strary_internal(register const char **lp, int n, register const char *fmt,
-       register int v)
+tok2strary_internal(const char **lp, int n, const char *fmt,
+       int v)
 {
        static char buf[TOKBUFSIZE];