diff options
author | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2017-12-13 19:17:47 +0100 |
---|---|---|
committer | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2017-12-13 19:17:47 +0100 |
commit | 5cea2703185c6af1616dc338c43c6cf67b0bec60 (patch) | |
tree | 004fe256b821973a0f2d249665b32666b6333490 | |
parent | e9306685c6fa9f76350334930ae14a935673f06b (diff) | |
download | tcpdump-5cea2703185c6af1616dc338c43c6cf67b0bec60.tar.gz |
Remove all storage class specifier 'register'
Let the compiler do the optimizations (or not) based on build options.
Avoid 'value has been optimized out' messages in gdb using '-O0'.
-rw-r--r-- | addrtoname.c | 106 | ||||
-rw-r--r-- | addrtoname.h | 2 | ||||
-rw-r--r-- | ascii_strcasecmp.c | 6 | ||||
-rw-r--r-- | checksum.c | 6 | ||||
-rw-r--r-- | gmt2local.c | 4 | ||||
-rw-r--r-- | in_cksum.c | 6 | ||||
-rw-r--r-- | missing/getservent.c | 2 | ||||
-rw-r--r-- | missing/strlcat.c | 6 | ||||
-rw-r--r-- | missing/strlcpy.c | 6 | ||||
-rw-r--r-- | missing/strsep.c | 6 | ||||
-rw-r--r-- | netdissect.h | 22 | ||||
-rw-r--r-- | parsenfsfh.c | 6 | ||||
-rw-r--r-- | print-ah.c | 4 | ||||
-rw-r--r-- | print-ap1394.c | 4 | ||||
-rw-r--r-- | print-ascii.c | 20 | ||||
-rw-r--r-- | print-atalk.c | 54 | ||||
-rw-r--r-- | print-bfd.c | 6 | ||||
-rw-r--r-- | print-bootp.c | 18 | ||||
-rw-r--r-- | print-carp.c | 2 | ||||
-rw-r--r-- | print-cfm.c | 4 | ||||
-rw-r--r-- | print-chdlc.c | 4 | ||||
-rw-r--r-- | print-cnfp.c | 12 | ||||
-rw-r--r-- | print-decnet.c | 14 | ||||
-rw-r--r-- | print-domain.c | 38 | ||||
-rw-r--r-- | print-dvmrp.c | 46 | ||||
-rw-r--r-- | print-eap.c | 2 | ||||
-rw-r--r-- | print-egp.c | 18 | ||||
-rw-r--r-- | print-eigrp.c | 2 | ||||
-rw-r--r-- | print-enc.c | 6 | ||||
-rw-r--r-- | print-esp.c | 4 | ||||
-rw-r--r-- | print-ether.c | 2 | ||||
-rw-r--r-- | print-fddi.c | 8 | ||||
-rw-r--r-- | print-forces.c | 88 | ||||
-rw-r--r-- | print-fr.c | 16 | ||||
-rw-r--r-- | print-frag6.c | 6 | ||||
-rw-r--r-- | print-hsrp.c | 2 | ||||
-rw-r--r-- | print-icmp.c | 6 | ||||
-rw-r--r-- | print-icmp6.c | 2 | ||||
-rw-r--r-- | print-igmp.c | 18 | ||||
-rw-r--r-- | print-igrp.c | 12 | ||||
-rw-r--r-- | print-ip.c | 18 | ||||
-rw-r--r-- | print-ip6.c | 8 | ||||
-rw-r--r-- | print-ip6opts.c | 4 | ||||
-rw-r--r-- | print-ipcomp.c | 4 | ||||
-rw-r--r-- | print-ipfc.c | 8 | ||||
-rw-r--r-- | print-ipx.c | 2 | ||||
-rw-r--r-- | print-juniper.c | 38 | ||||
-rw-r--r-- | print-krb.c | 12 | ||||
-rw-r--r-- | print-ldp.c | 8 | ||||
-rw-r--r-- | print-llc.c | 4 | ||||
-rw-r--r-- | print-lldp.c | 2 | ||||
-rw-r--r-- | print-lmp.c | 2 | ||||
-rw-r--r-- | print-lspping.c | 2 | ||||
-rw-r--r-- | print-lwres.c | 2 | ||||
-rw-r--r-- | print-mpcp.c | 2 | ||||
-rw-r--r-- | print-nfs.c | 46 | ||||
-rw-r--r-- | print-ntp.c | 44 | ||||
-rw-r--r-- | print-ospf.c | 58 | ||||
-rw-r--r-- | print-ospf6.c | 56 | ||||
-rw-r--r-- | print-pflog.c | 2 | ||||
-rw-r--r-- | print-pgm.c | 12 | ||||
-rw-r--r-- | print-pim.c | 18 | ||||
-rw-r--r-- | print-ppp.c | 22 | ||||
-rw-r--r-- | print-pppoe.c | 4 | ||||
-rw-r--r-- | print-radius.c | 42 | ||||
-rw-r--r-- | print-resp.c | 36 | ||||
-rw-r--r-- | print-rip.c | 16 | ||||
-rw-r--r-- | print-ripng.c | 6 | ||||
-rw-r--r-- | print-rpki-rtr.c | 2 | ||||
-rw-r--r-- | print-rrcp.c | 2 | ||||
-rw-r--r-- | print-rsvp.c | 2 | ||||
-rw-r--r-- | print-rt6.c | 10 | ||||
-rw-r--r-- | print-rx.c | 38 | ||||
-rw-r--r-- | print-sl.c | 30 | ||||
-rw-r--r-- | print-sll.c | 4 | ||||
-rw-r--r-- | print-slow.c | 10 | ||||
-rw-r--r-- | print-snmp.c | 10 | ||||
-rw-r--r-- | print-sunrpc.c | 12 | ||||
-rw-r--r-- | print-symantec.c | 4 | ||||
-rw-r--r-- | print-syslog.c | 2 | ||||
-rw-r--r-- | print-tcp.c | 50 | ||||
-rw-r--r-- | print-tftp.c | 6 | ||||
-rw-r--r-- | print-timed.c | 2 | ||||
-rw-r--r-- | print-token.c | 4 | ||||
-rw-r--r-- | print-udp.c | 28 | ||||
-rw-r--r-- | print-usb.c | 4 | ||||
-rw-r--r-- | print-vjc.c | 2 | ||||
-rw-r--r-- | print-vqp.c | 2 | ||||
-rw-r--r-- | print-vrrp.c | 4 | ||||
-rw-r--r-- | print-wb.c | 4 | ||||
-rw-r--r-- | tcpdump.c | 16 | ||||
-rw-r--r-- | util-print.c | 56 |
92 files changed, 689 insertions, 689 deletions
diff --git a/addrtoname.c b/addrtoname.c index 003ce512..9d5c88cc 100644 --- a/addrtoname.c +++ b/addrtoname.c @@ -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; diff --git a/addrtoname.h b/addrtoname.h index c3019194..8a37d3d5 100644 --- a/addrtoname.h +++ b/addrtoname.h @@ -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 *); diff --git a/ascii_strcasecmp.c b/ascii_strcasecmp.c index b8decf14..090f7586 100644 --- a/ascii_strcasecmp.c +++ b/ascii_strcasecmp.c @@ -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; @@ -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++ ) { diff --git a/gmt2local.c b/gmt2local.c index d6cd93b8..4d392207 100644 --- a/gmt2local.c +++ b/gmt2local.c @@ -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) @@ -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 { diff --git a/missing/getservent.c b/missing/getservent.c index 48b7465c..043b8285 100644 --- a/missing/getservent.c +++ b/missing/getservent.c @@ -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); diff --git a/missing/strlcat.c b/missing/strlcat.c index 40549354..f41207be 100644 --- a/missing/strlcat.c +++ b/missing/strlcat.c @@ -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 */ diff --git a/missing/strlcpy.c b/missing/strlcpy.c index 24dcca67..2dc51b96 100644 --- a/missing/strlcpy.c +++ b/missing/strlcpy.c @@ -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) { diff --git a/missing/strsep.c b/missing/strsep.c index 2c17275f..05f10bcc 100644 --- a/missing/strsep.c +++ b/missing/strsep.c @@ -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) diff --git a/netdissect.h b/netdissect.h index 11907ea9..70c821d9 100644 --- a/netdissect.h +++ b/netdissect.h @@ -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); diff --git a/parsenfsfh.c b/parsenfsfh.c index 8f48e774..f5457917 100644 --- a/parsenfsfh.c +++ b/parsenfsfh.c @@ -105,13 +105,13 @@ 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; /* @@ -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; diff --git a/print-ap1394.c b/print-ap1394.c index 869fbcb9..4c463ada 100644 --- a/print-ap1394.c +++ b/print-ap1394.c @@ -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; diff --git a/print-ascii.c b/print-ascii.c index 2e5812e4..14e50bd5 100644 --- a/print-ascii.c +++ b/print-ascii.c @@ -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) diff --git a/print-atalk.c b/print-atalk.c index f8f95de4..462447d8 100644 --- a/print-atalk.c +++ b/print-atalk.c @@ -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]; diff --git a/print-bfd.c b/print-bfd.c index 45ec2c5c..e52fbf2b 100644 --- a/print-bfd.c +++ b/print-bfd.c @@ -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; diff --git a/print-bootp.c b/print-bootp.c index 8e225f85..eb55fdb5 100644 --- a/print-bootp.c +++ b/print-bootp.c @@ -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) \ diff --git a/print-carp.c b/print-carp.c index 58981554..807e977f 100644 --- a/print-carp.c +++ b/print-carp.c @@ -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; diff --git a/print-cfm.c b/print-cfm.c index 0a666478..bc5125f1 100644 --- a/print-cfm.c +++ b/print-cfm.c @@ -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; diff --git a/print-chdlc.c b/print-chdlc.c index 1c6fe36b..9893f773 100644 --- a/print-chdlc.c +++ b/print-chdlc.c @@ -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; diff --git a/print-cnfp.c b/print-cnfp.c index 162b1f9f..e9e9e6db 100644 --- a/print-cnfp.c +++ b/print-cnfp.c @@ -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 diff --git a/print-decnet.c b/print-decnet.c index 51070119..b86bd889 100644 --- a/print-decnet.c +++ b/print-decnet.c @@ -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))); } diff --git a/print-domain.c b/print-domain.c index 303dc28c..ea80aeba 100644 --- a/print-domain.c +++ b/print-domain.c @@ -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; diff --git a/print-dvmrp.c b/print-dvmrp.c index cfc3f710..91daec83 100644 --- a/print-dvmrp.c +++ b/print-dvmrp.c @@ -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))); diff --git a/print-eap.c b/print-eap.c index 95eaa17a..827bf672 100644 --- a/print-eap.c +++ b/print-eap.c @@ -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; diff --git a/print-egp.c b/print-egp.c index 7bcf16cf..b5306d02 100644 --- a/print-egp.c +++ b/print-egp.c @@ -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)) { diff --git a/print-eigrp.c b/print-eigrp.c index 2a139151..95a00ef6 100644 --- a/print-eigrp.c +++ b/print-eigrp.c @@ -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; diff --git a/print-enc.c b/print-enc.c index 4a43a491..c3fcf10c 100644 --- a/print-enc.c +++ b/print-enc.c @@ -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; diff --git a/print-esp.c b/print-esp.c index d71bd23e..ade700a2 100644 --- a/print-esp.c +++ b/print-esp.c @@ -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; diff --git a/print-ether.c b/print-ether.c index 7e7216c4..ce96e62e 100644 --- a/print-ether.c +++ b/print-ether.c @@ -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; diff --git a/print-fddi.c b/print-fddi.c index 01f376f8..0b85034a 100644 --- a/print-fddi.c +++ b/print-fddi.c @@ -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)); } diff --git a/print-forces.c b/print-forces.c index 5209990e..f6be80c2 100644 --- a/print-forces.c +++ b/print-forces.c @@ -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; @@ -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; diff --git a/print-frag6.c b/print-frag6.c index fe8f3cf7..f1728f0c 100644 --- a/print-frag6.c +++ b/print-frag6.c @@ -33,10 +33,10 @@ #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; diff --git a/print-hsrp.c b/print-hsrp.c index 35146460..a6ad21b6 100644 --- a/print-hsrp.c +++ b/print-hsrp.c @@ -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; diff --git a/print-icmp.c b/print-icmp.c index ff65a854..4ebd977b 100644 --- a/print-icmp.c +++ b/print-icmp.c @@ -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"); diff --git a/print-icmp6.c b/print-icmp6.c index 2fd9d1b4..b2230f60 100644 --- a/print-icmp6.c +++ b/print-icmp6.c @@ -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) { diff --git a/print-igmp.c b/print-igmp.c index d0dfd329..d5356dd2 100644 --- a/print-igmp.c +++ b/print-igmp.c @@ -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]; diff --git a/print-igrp.c b/print-igrp.c index 10915f88..57df70f9 100644 --- a/print-igrp.c +++ b/print-igrp.c @@ -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; @@ -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)); diff --git a/print-ip6.c b/print-ip6.c index 3b63639e..72297aae 100644 --- a/print-ip6.c +++ b/print-ip6.c @@ -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; diff --git a/print-ip6opts.c b/print-ip6opts.c index 95e52e4b..00cad391 100644 --- a/print-ip6opts.c +++ b/print-ip6opts.c @@ -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; diff --git a/print-ipcomp.c b/print-ipcomp.c index 8e5252b2..3d526d55 100644 --- a/print-ipcomp.c +++ b/print-ipcomp.c @@ -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; diff --git a/print-ipfc.c b/print-ipfc.c index 2ba51271..b67e7f2d 100644 --- a/print-ipfc.c +++ b/print-ipfc.c @@ -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)); } diff --git a/print-ipx.c b/print-ipx.c index ac080121..9f3430f9 100644 --- a/print-ipx.c +++ b/print-ipx.c @@ -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) { diff --git a/print-juniper.c b/print-juniper.c index 55564579..2d88b604 100644 --- a/print-juniper.c +++ b/print-juniper.c @@ -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: diff --git a/print-krb.c b/print-krb.c index de025f93..b6c78298 100644 --- a/print-krb.c +++ b/print-krb.c @@ -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; diff --git a/print-ldp.c b/print-ldp.c index e107c52b..ab4f6c63 100644 --- a/print-ldp.c +++ b/print-ldp.c @@ -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; diff --git a/print-llc.c b/print-llc.c index cd368b3f..3d0a7cd0 100644 --- a/print-llc.c +++ b/print-llc.c @@ -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) diff --git a/print-lldp.c b/print-lldp.c index 90dba8ee..f4752d49 100644 --- a/print-lldp.c +++ b/print-lldp.c @@ -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; diff --git a/print-lmp.c b/print-lmp.c index 295c0242..4acd8890 100644 --- a/print-lmp.c +++ b/print-lmp.c @@ -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; diff --git a/print-lspping.c b/print-lspping.c index f32bbde7..09e8317f 100644 --- a/print-lspping.c +++ b/print-lspping.c @@ -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; diff --git a/print-lwres.c b/print-lwres.c index ff6d908c..f6793a61 100644 --- a/print-lwres.c +++ b/print-lwres.c @@ -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; diff --git a/print-mpcp.c b/print-mpcp.c index 1f6446e3..8f988357 100644 --- a/print-mpcp.c +++ b/print-mpcp.c @@ -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; diff --git a/print-nfs.c b/print-nfs.c index 797f53ad..45b42787 100644 --- a/print-nfs.c +++ b/print-nfs.c @@ -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); diff --git a/print-ntp.c b/print-ntp.c index c482697d..58d9843d 100644 --- a/print-ntp.c +++ b/print-ntp.c @@ -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; diff --git a/print-ospf.c b/print-ospf.c index 4453a47e..025d97e1 100644 --- a/print-ospf.c +++ b/print-ospf.c @@ -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; diff --git a/print-ospf6.c b/print-ospf6.c index 68c6ee03..e38c4557 100644 --- a/print-ospf6.c +++ b/print-ospf6.c @@ -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; diff --git a/print-pflog.c b/print-pflog.c index d53fea81..d0269af0 100644 --- a/print-pflog.c +++ b/print-pflog.c @@ -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; diff --git a/print-pgm.c b/print-pgm.c index 04b654ef..1cf9bd20 100644 --- a/print-pgm.c +++ b/print-pgm.c @@ -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; diff --git a/print-pim.c b/print-pim.c index c479c7b0..8e52de5a 100644 --- a/print-pim.c +++ b/print-pim.c @@ -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; diff --git a/print-ppp.c b/print-ppp.c index a79906f8..3b935ed5 100644 --- a/print-ppp.c +++ b/print-ppp.c @@ -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; diff --git a/print-pppoe.c b/print-pppoe.c index b2efcc32..fe108396 100644 --- a/print-pppoe.c +++ b/print-pppoe.c @@ -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; diff --git a/print-radius.c b/print-radius.c index 904f6594..9047cd14 100644 --- a/print-radius.c +++ b/print-radius.c @@ -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); diff --git a/print-resp.c b/print-resp.c index 736b933e..1d24b58e 100644 --- a/print-resp.c +++ b/print-resp.c @@ -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; diff --git a/print-rip.c b/print-rip.c index 4bc07095..eebb3ff0 100644 --- a/print-rip.c +++ b/print-rip.c @@ -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)); diff --git a/print-ripng.c b/print-ripng.c index 19398931..daf7bd37 100644 --- a/print-ripng.c +++ b/print-ripng.c @@ -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; diff --git a/print-rpki-rtr.c b/print-rpki-rtr.c index 47a13114..45e2787d 100644 --- a/print-rpki-rtr.c +++ b/print-rpki-rtr.c @@ -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")); diff --git a/print-rrcp.c b/print-rrcp.c index ecfa3740..0885f646 100644 --- a/print-rrcp.c +++ b/print-rrcp.c @@ -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) diff --git a/print-rsvp.c b/print-rsvp.c index dfedaf50..29d27412 100644 --- a/print-rsvp.c +++ b/print-rsvp.c @@ -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; diff --git a/print-rt6.c b/print-rt6.c index 66c41758..269496aa 100644 --- a/print-rt6.c +++ b/print-rt6.c @@ -36,13 +36,13 @@ #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; @@ -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; @@ -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++; diff --git a/print-sll.c b/print-sll.c index 53ee4e96..0f0a2e7f 100644 --- a/print-sll.c +++ b/print-sll.c @@ -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; diff --git a/print-slow.c b/print-slow.c index c6b6bd7c..57fa595a 100644 --- a/print-slow.c +++ b/print-slow.c @@ -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; diff --git a/print-snmp.c b/print-snmp.c index 1fdd5bf8..976264c6 100644 --- a/print-snmp.c +++ b/print-snmp.c @@ -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; diff --git a/print-sunrpc.c b/print-sunrpc.c index ce8b0393..239742bc 100644 --- a/print-sunrpc.c +++ b/print-sunrpc.c @@ -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; diff --git a/print-symantec.c b/print-symantec.c index 56f7fc26..e80bd45c 100644 --- a/print-symantec.c +++ b/print-symantec.c @@ -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; diff --git a/print-syslog.c b/print-syslog.c index 1610bd6d..901c6f3a 100644 --- a/print-syslog.c +++ b/print-syslog.c @@ -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; diff --git a/print-tcp.c b/print-tcp.c index 70af9b61..9e449fe4 100644 --- a/print-tcp.c +++ b/print-tcp.c @@ -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; diff --git a/print-tftp.c b/print-tftp.c index 5ebf9333..e0bedc39 100644 --- a/print-tftp.c +++ b/print-tftp.c @@ -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 */ diff --git a/print-timed.c b/print-timed.c index 33397c0d..34eb6168 100644 --- a/print-timed.c +++ b/print-timed.c @@ -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; diff --git a/print-token.c b/print-token.c index 5cca3b07..ff2a3841 100644 --- a/print-token.c +++ b/print-token.c @@ -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; diff --git a/print-udp.c b/print-udp.c index c58339e9..7fe4b9de 100644 --- a/print-udp.c +++ b/print-udp.c @@ -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); diff --git a/print-usb.c b/print-usb.c index 04862881..5e425f16 100644 --- a/print-usb.c +++ b/print-usb.c @@ -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)); diff --git a/print-vjc.c b/print-vjc.c index 5cccd73f..0743cfa0 100644 --- a/print-vjc.c +++ b/print-vjc.c @@ -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; diff --git a/print-vqp.c b/print-vqp.c index 5dd9939b..ebc25fc9 100644 --- a/print-vqp.c +++ b/print-vqp.c @@ -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; diff --git a/print-vrrp.c b/print-vrrp.c index d9aa4b81..b7e309d0 100644 --- a/print-vrrp.c +++ b/print-vrrp.c @@ -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; @@ -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)) { @@ -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; diff --git a/util-print.c b/util-print.c index 13191e9c..4ac4bc49 100644 --- a/util-print.c +++ b/util-print.c @@ -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]; |