Revision: 582 http://sourceforge.net/p/vde/svn/582 Author: garden Date: 2014-10-12 20:17:24 +0000 (Sun, 12 Oct 2014) Log Message: ----------- In 2014, I think we can stop trying to outsmart the compiler. Remove "register" storage class.
Modified Paths: -------------- trunk/vde-2/src/common/poll.c trunk/vde-2/src/dpipe.c trunk/vde-2/src/kvde_switch/consmgmt.c trunk/vde-2/src/kvde_switch/kvde_switch.c trunk/vde-2/src/lib/libvdehist.c trunk/vde-2/src/lib/libvdeplug.c trunk/vde-2/src/slirpvde/cksum.c trunk/vde-2/src/slirpvde/ip_icmp.c trunk/vde-2/src/slirpvde/ip_input.c trunk/vde-2/src/slirpvde/ip_output.c trunk/vde-2/src/slirpvde/mbuf.c trunk/vde-2/src/slirpvde/mbuf.h trunk/vde-2/src/slirpvde/misc.c trunk/vde-2/src/slirpvde/slirp.h trunk/vde-2/src/slirpvde/slirpvde.c trunk/vde-2/src/slirpvde/socket.h trunk/vde-2/src/slirpvde/tcp_input.c trunk/vde-2/src/slirpvde/tcp_output.c trunk/vde-2/src/slirpvde/tcp_subr.c trunk/vde-2/src/slirpvde/tcp_timer.c trunk/vde-2/src/slirpvde/udp.c trunk/vde-2/src/slirpvde/udp.h trunk/vde-2/src/vde_autolink.c trunk/vde-2/src/vde_cryptcab/crc32.c trunk/vde-2/src/vde_l3/vde_l3.c trunk/vde-2/src/vde_plug.c trunk/vde-2/src/vde_router/rbtree.c trunk/vde-2/src/vde_switch/bitarray.h trunk/vde-2/src/vde_switch/consmgmt.c trunk/vde-2/src/vde_switch/fstp.c trunk/vde-2/src/vde_switch/hash.c trunk/vde-2/src/vde_switch/port.c trunk/vde-2/src/vde_switch/qtimer.c trunk/vde-2/src/vde_switch/vde_switch.c trunk/vde-2/src/vde_vxlan/vxlan_hash.c trunk/vde-2/src/vdeq.c trunk/vde-2/src/vdetaplib/libvdetap.c trunk/vde-2/src/vdetaplib/vdetap.c trunk/vde-2/src/wirefilter.c Modified: trunk/vde-2/src/common/poll.c =================================================================== --- trunk/vde-2/src/common/poll.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/common/poll.c 2014-10-12 20:17:24 UTC (rev 582) @@ -22,7 +22,7 @@ static int prepare_select(struct pollfd *ufds, nfds_t nfds, int timeout, struct timeval **pstimeout, int *maxfdp1, fd_set *rfds, fd_set *wfds, fd_set *efds) { - register int i; + int i; struct pollfd *currfd; struct timeval *stimeout = *pstimeout; @@ -93,7 +93,7 @@ static int convert_results(struct pollfd *ufds, int nfds, fd_set *rfds, fd_set *wfds, fd_set *efds) { - register int i; + int i; struct pollfd *currfd; int retval = 0; Modified: trunk/vde-2/src/dpipe.c =================================================================== --- trunk/vde-2/src/dpipe.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/dpipe.c 2014-10-12 20:17:24 UTC (rev 582) @@ -29,7 +29,7 @@ int splitindex(int argc, char *argv[], int *dirchar) { - register int i; + int i; for (i=0; i<argc; i++) { if (*dirchar == argv[i][0] && argv[i][1] == '=' ) { Modified: trunk/vde-2/src/kvde_switch/consmgmt.c =================================================================== --- trunk/vde-2/src/kvde_switch/consmgmt.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/kvde_switch/consmgmt.c 2014-10-12 20:17:24 UTC (rev 582) @@ -72,7 +72,7 @@ void addcl(int ncl,struct comlist *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { cl->next=NULL; (*clt)=cl; @@ -82,9 +82,9 @@ void delcl(int ncl,struct comlist *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { - register struct comlist **p=&clh; + struct comlist **p=&clh; while (*p != NULL) { if (*p == cl) *p=cl->next; @@ -109,9 +109,9 @@ void deldbgcl(int ncl,struct dbgcl *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { - register struct dbgcl **p=&dbgclh; + struct dbgcl **p=&dbgclh; while (*p != NULL) { if (*p == cl) { if (cl->fds) free(cl->fds); @@ -136,7 +136,7 @@ void delplugin(struct plugin *cl) { - register struct plugin **p=&pluginh; + struct plugin **p=&pluginh; while (*p != NULL) { if (*p == cl) *p=cl->next; Modified: trunk/vde-2/src/kvde_switch/kvde_switch.c =================================================================== --- trunk/vde-2/src/kvde_switch/kvde_switch.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/kvde_switch/kvde_switch.c 2014-10-12 20:17:24 UTC (rev 582) @@ -102,7 +102,7 @@ unsigned char add_type(struct swmodule *mgr,int prio) { - register int i; + int i; if(ntypes==maxtypes) { maxtypes = maxtypes ? 2 * maxtypes : 8; if (maxtypes > PRIOFLAG) { @@ -168,14 +168,14 @@ static void file_cleanup(void) { - register int i; + int i; for(i = 0; i < nfds; i++) TYPE2MGR(fdpp[i]->type)->cleanup(fdpp[i]->type,fds[i].fd,fdpp[i]->private_data); } void remove_fd(int fd) { - register int i; + int i; for(i = 0; i < nfds; i++){ if(fds[i].fd == fd) break; @@ -196,7 +196,7 @@ static void main_loop() { time_t now; - register int n,i; + int n,i; while(1) { n=poll(fds,nfds,-1); now=time(NULL); @@ -206,7 +206,7 @@ } else { for(i = 0; /*i < nfds &&*/ n>0; i++){ if(fds[i].revents != 0) { - register int prenfds=nfds; + int prenfds=nfds; n--; fdpp[i]->timestamp=now; TYPE2MGR(fdpp[i]->type)->handle_io(fdpp[i]->type,fds[i].fd,fds[i].revents,fdpp[i]->private_data); @@ -258,7 +258,7 @@ static struct option *optcpy(struct option *tgt, struct option *src, int n, int tag) { - register int i; + int i; memcpy(tgt,src,sizeof(struct option) * n); for (i=0;i<n;i++) { tgt[i].val=(tgt[i].val & 0xffff) | tag << 16; @@ -303,7 +303,7 @@ if (long_options == NULL || optstring==NULL) exit(2); { /* fill-in the long_options fields */ - register int i; + int i; char *os=optstring; char last=0; struct option *opp=long_options; Modified: trunk/vde-2/src/lib/libvdehist.c =================================================================== --- trunk/vde-2/src/lib/libvdehist.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/lib/libvdehist.c 2014-10-12 20:17:24 UTC (rev 582) @@ -397,7 +397,7 @@ static int telnet_options(struct vdehiststat *st,unsigned char *s) { - register int action_n_object; + int action_n_object; if (st->telnetprotocol == 0) { st->telnetprotocol=1; st->echo=0; Modified: trunk/vde-2/src/lib/libvdeplug.c =================================================================== --- trunk/vde-2/src/lib/libvdeplug.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/lib/libvdeplug.c 2014-10-12 20:17:24 UTC (rev 582) @@ -749,7 +749,7 @@ //fprintf(stderr,"%s: splitpacket rnx=%d remaining=%d size=%d\n",myname,rnx,vdestream->remaining,len); if (len==0) return; if (vdestream->rnx>0) { - register int amount=MIN(vdestream->remaining,len); + int amount=MIN(vdestream->remaining,len); //fprintf(stderr,"%s: fragment amount %d\n",myname,amount); memcpy(vdestream->fragp,buf,amount); vdestream->remaining-=amount; Modified: trunk/vde-2/src/slirpvde/cksum.c =================================================================== --- trunk/vde-2/src/slirpvde/cksum.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/cksum.c 2014-10-12 20:17:24 UTC (rev 582) @@ -47,8 +47,8 @@ int cksum(struct mbuf *m, int len) { register u_int16_t *w; - register int sum = 0; - register int mlen = 0; + int sum = 0; + int mlen = 0; int byte_swapped = 0; union { Modified: trunk/vde-2/src/slirpvde/ip_icmp.c =================================================================== --- trunk/vde-2/src/slirpvde/ip_icmp.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/ip_icmp.c 2014-10-12 20:17:24 UTC (rev 582) @@ -66,8 +66,8 @@ void icmp_input(struct mbuf *m, int hlen) { - register struct icmp *icp; - register struct ip *ip=mtod(m, struct ip *); + struct icmp *icp; + struct ip *ip=mtod(m, struct ip *); int icmplen=ip->ip_len; Slirp *slirp = m->slirp; @@ -190,9 +190,9 @@ const char *message) { unsigned hlen, shlen, s_ip_len; - register struct ip *ip; - register struct icmp *icp; - register struct mbuf *m; + struct ip *ip; + struct icmp *icp; + struct mbuf *m; DEBUG_CALL("icmp_error"); DEBUG_ARG("msrc = %lx", (long )msrc); @@ -306,10 +306,10 @@ void icmp_reflect(struct mbuf *m) { - register struct ip *ip = mtod(m, struct ip *); + struct ip *ip = mtod(m, struct ip *); int hlen = ip->ip_hl << 2; int optlen = hlen - sizeof(struct ip ); - register struct icmp *icp; + struct icmp *icp; /* * Send an icmp packet back to the ip level, Modified: trunk/vde-2/src/slirpvde/ip_input.c =================================================================== --- trunk/vde-2/src/slirpvde/ip_input.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/ip_input.c 2014-10-12 20:17:24 UTC (rev 582) @@ -44,9 +44,9 @@ static struct ip *ip_reass(Slirp *slirp, struct ip *ip, struct ipq *fp); static void ip_freef(Slirp *slirp, struct ipq *fp); -static void ip_enq(register struct ipasfrag *p, - register struct ipasfrag *prev); -static void ip_deq(register struct ipasfrag *p); +static void ip_enq(struct ipasfrag *p, + struct ipasfrag *prev); +static void ip_deq(struct ipasfrag *p); /* * IP initialization: fill in IP protocol switch table. @@ -68,7 +68,7 @@ ip_input(struct mbuf *m) { Slirp *slirp = m->slirp; - register struct ip *ip; + struct ip *ip; int hlen; DEBUG_CALL("ip_input"); @@ -159,7 +159,7 @@ * XXX This should fail, don't fragment yet */ if (ip->ip_off &~ IP_DF) { - register struct ipq *fp; + struct ipq *fp; struct qlink *l; /* * Look for queue of fragments @@ -240,8 +240,8 @@ static struct ip * ip_reass(Slirp *slirp, struct ip *ip, struct ipq *fp) { - register struct mbuf *m = dtom(slirp, ip); - register struct ipasfrag *q; + struct mbuf *m = dtom(slirp, ip); + struct ipasfrag *q; int hlen = ip->ip_hl << 2; int i, next; @@ -395,7 +395,7 @@ static void ip_freef(Slirp *slirp, struct ipq *fp) { - register struct ipasfrag *q, *p; + struct ipasfrag *q, *p; for (q = fp->frag_link.next; q != (struct ipasfrag*)&fp->frag_link; q = p) { p = q->ipf_next; @@ -411,7 +411,7 @@ * Like insque, but pointers in middle of structure. */ static void -ip_enq(register struct ipasfrag *p, register struct ipasfrag *prev) +ip_enq(struct ipasfrag *p, struct ipasfrag *prev) { DEBUG_CALL("ip_enq"); DEBUG_ARG("prev = %lx", (long)prev); @@ -425,7 +425,7 @@ * To ip_enq as remque is to insque. */ static void -ip_deq(register struct ipasfrag *p) +ip_deq(struct ipasfrag *p) { ((struct ipasfrag *)(p->ipf_prev))->ipf_next = p->ipf_next; ((struct ipasfrag *)(p->ipf_next))->ipf_prev = p->ipf_prev; @@ -471,10 +471,10 @@ ip_dooptions(m) struct mbuf *m; { - register struct ip *ip = mtod(m, struct ip *); + struct ip *ip = mtod(m, struct ip *); register u_char *cp; - register struct ip_timestamp *ipt; - register struct in_ifaddr *ia; + struct ip_timestamp *ipt; + struct in_ifaddr *ia; int opt, optlen, cnt, off, code, type, forward = 0; struct in_addr *sin, dst; typedef u_int32_t n_time; @@ -665,9 +665,9 @@ * (XXX) should be deleted; last arg currently ignored. */ void -ip_stripoptions(register struct mbuf *m, struct mbuf *mopt) +ip_stripoptions(struct mbuf *m, struct mbuf *mopt) { - register int i; + int i; struct ip *ip = mtod(m, struct ip *); register caddr_t opts; int olen; Modified: trunk/vde-2/src/slirpvde/ip_output.c =================================================================== --- trunk/vde-2/src/slirpvde/ip_output.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/ip_output.c 2014-10-12 20:17:24 UTC (rev 582) @@ -54,9 +54,9 @@ ip_output(struct socket *so, struct mbuf *m0) { Slirp *slirp = m0->slirp; - register struct ip *ip; - register struct mbuf *m = m0; - register int hlen = sizeof(struct ip ); + struct ip *ip; + struct mbuf *m = m0; + int hlen = sizeof(struct ip ); int len, off, error = 0; DEBUG_CALL("ip_output"); @@ -111,7 +111,7 @@ m0 = m; mhlen = sizeof (struct ip); for (off = hlen + len; off < (u_int16_t)ip->ip_len; off += len) { - register struct ip *mhip; + struct ip *mhip; m = m_get(slirp); if (m == NULL) { error = -1; Modified: trunk/vde-2/src/slirpvde/mbuf.c =================================================================== --- trunk/vde-2/src/slirpvde/mbuf.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/mbuf.c 2014-10-12 20:17:24 UTC (rev 582) @@ -43,7 +43,7 @@ struct mbuf * m_get(Slirp *slirp) { - register struct mbuf *m; + struct mbuf *m; int flags = 0; DEBUG_CALL("m_get"); Modified: trunk/vde-2/src/slirpvde/mbuf.h =================================================================== --- trunk/vde-2/src/slirpvde/mbuf.h 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/mbuf.h 2014-10-12 20:17:24 UTC (rev 582) @@ -118,7 +118,7 @@ void m_init(Slirp *); struct mbuf * m_get(Slirp *); void m_free(struct mbuf *); -void m_cat(register struct mbuf *, register struct mbuf *); +void m_cat(struct mbuf *, struct mbuf *); void m_inc(struct mbuf *, int); void m_adj(struct mbuf *, int); int m_copy(struct mbuf *, struct mbuf *, int, int); Modified: trunk/vde-2/src/slirpvde/misc.c =================================================================== --- trunk/vde-2/src/slirpvde/misc.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/misc.c 2014-10-12 20:17:24 UTC (rev 582) @@ -24,8 +24,8 @@ inline void insque(void *a, void *b) { - register struct quehead *element = (struct quehead *) a; - register struct quehead *head = (struct quehead *) b; + struct quehead *element = (struct quehead *) a; + struct quehead *head = (struct quehead *) b; element->qh_link = head->qh_link; head->qh_link = (struct quehead *)element; element->qh_rlink = (struct quehead *)head; @@ -36,7 +36,7 @@ inline void remque(void *a) { - register struct quehead *element = (struct quehead *) a; + struct quehead *element = (struct quehead *) a; ((struct quehead *)(element->qh_link))->qh_rlink = element->qh_rlink; ((struct quehead *)(element->qh_rlink))->qh_link = element->qh_link; element->qh_rlink = NULL; Modified: trunk/vde-2/src/slirpvde/slirp.h =================================================================== --- trunk/vde-2/src/slirpvde/slirp.h 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/slirp.h 2014-10-12 20:17:24 UTC (rev 582) @@ -316,25 +316,25 @@ void ip_init(Slirp *); void ip_input(struct mbuf *); void ip_slowtimo(Slirp *); -void ip_stripoptions(register struct mbuf *, struct mbuf *); +void ip_stripoptions(struct mbuf *, struct mbuf *); /* ip_output.c */ int ip_output(struct socket *, struct mbuf *); /* tcp_input.c */ -void tcp_input(register struct mbuf *, int, struct socket *); -int tcp_mss(register struct tcpcb *, u_int); +void tcp_input(struct mbuf *, int, struct socket *); +int tcp_mss(struct tcpcb *, u_int); /* tcp_output.c */ -int tcp_output(register struct tcpcb *); -void tcp_setpersist(register struct tcpcb *); +int tcp_output(struct tcpcb *); +void tcp_setpersist(struct tcpcb *); /* tcp_subr.c */ void tcp_init(Slirp *); void tcp_template(struct tcpcb *); -void tcp_respond(struct tcpcb *, register struct tcpiphdr *, register struct mbuf *, tcp_seq, tcp_seq, int); +void tcp_respond(struct tcpcb *, struct tcpiphdr *, struct mbuf *, tcp_seq, tcp_seq, int); struct tcpcb * tcp_newtcpcb(struct socket *); -struct tcpcb * tcp_close(register struct tcpcb *); +struct tcpcb * tcp_close(struct tcpcb *); void tcp_sockclosed(struct tcpcb *); int tcp_fconnect(struct socket *); void tcp_connect(struct socket *); Modified: trunk/vde-2/src/slirpvde/slirpvde.c =================================================================== --- trunk/vde-2/src/slirpvde/slirpvde.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/slirpvde.c 2014-10-12 20:17:24 UTC (rev 582) @@ -138,7 +138,7 @@ #define convery2ascii(x) ((x)>=' ' && (x) <= '~')?(x):'.' void dumppkt(const uint8_t *pkt, int pkt_len) { - register int i,j; + int i,j; printf("Packet dump len=%d\n",pkt_len); if (pkt_len == 0) return; @@ -354,7 +354,7 @@ char *sockname=NULL; int result,nfds; register ssize_t nx; - /*register int i;*/ + /*int i;*/ fd_set rs,ws,xs; int opt,longindx; int daemonize=0; Modified: trunk/vde-2/src/slirpvde/socket.h =================================================================== --- trunk/vde-2/src/slirpvde/socket.h 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/socket.h 2014-10-12 20:17:24 UTC (rev 582) @@ -85,8 +85,8 @@ int sosendto(struct socket *, struct mbuf *); struct socket * tcp_listen(Slirp *, u_int32_t, u_int, u_int32_t, u_int, int); -void soisfconnecting(register struct socket *); -void soisfconnected(register struct socket *); +void soisfconnecting(struct socket *); +void soisfconnected(struct socket *); void sofwdrain(struct socket *); struct iovec; /* For win32 */ size_t sopreprbuf(struct socket *so, struct iovec *iov, int *np); Modified: trunk/vde-2/src/slirpvde/tcp_input.c =================================================================== --- trunk/vde-2/src/slirpvde/tcp_input.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/tcp_input.c 2014-10-12 20:17:24 UTC (rev 582) @@ -99,13 +99,13 @@ #endif static void tcp_dooptions(struct tcpcb *tp, u_char *cp, int cnt, struct tcpiphdr *ti); -static void tcp_xmit_timer(register struct tcpcb *tp, int rtt); +static void tcp_xmit_timer(struct tcpcb *tp, int rtt); static int -tcp_reass(register struct tcpcb *tp, register struct tcpiphdr *ti, +tcp_reass(struct tcpcb *tp, struct tcpiphdr *ti, struct mbuf *m) { - register struct tcpiphdr *q; + struct tcpiphdr *q; struct socket *so = tp->t_socket; int flags; @@ -130,7 +130,7 @@ * segment. If it provides all of our data, drop us. */ if (!tcpfrag_list_end(tcpiphdr_prev(q), tp)) { - register int i; + int i; q = tcpiphdr_prev(q); /* conversion to int (in i) handles seq wraparound */ i = q->ti_seq + q->ti_len - ti->ti_seq; @@ -158,7 +158,7 @@ * if they are completely covered, dequeue them. */ while (!tcpfrag_list_end(q, tp)) { - register int i = (ti->ti_seq + ti->ti_len) - q->ti_seq; + int i = (ti->ti_seq + ti->ti_len) - q->ti_seq; if (i <= 0) break; if (i < q->ti_len) { @@ -216,12 +216,12 @@ tcp_input(struct mbuf *m, int iphlen, struct socket *inso) { struct ip save_ip, *ip; - register struct tcpiphdr *ti; + struct tcpiphdr *ti; caddr_t optp = NULL; int optlen = 0; int len, tlen, off; - register struct tcpcb *tp = NULL; - register int tiflags; + struct tcpcb *tp = NULL; + int tiflags; struct socket *so = NULL; int todrop, acked, ourfinisacked, needoutput = 0; int iss = 0; @@ -1343,7 +1343,7 @@ tcp_pulloutofband(so, ti, m) struct socket *so; struct tcpiphdr *ti; - register struct mbuf *m; + struct mbuf *m; { int cnt = ti->ti_urp - 1; @@ -1374,7 +1374,7 @@ */ static void -tcp_xmit_timer(register struct tcpcb *tp, int rtt) +tcp_xmit_timer(struct tcpcb *tp, int rtt) { register short delta; Modified: trunk/vde-2/src/slirpvde/tcp_output.c =================================================================== --- trunk/vde-2/src/slirpvde/tcp_output.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/tcp_output.c 2014-10-12 20:17:24 UTC (rev 582) @@ -55,11 +55,11 @@ int tcp_output(struct tcpcb *tp) { - register struct socket *so = tp->t_socket; - register long len, win; + struct socket *so = tp->t_socket; + long len, win; int off, flags, error; - register struct mbuf *m; - register struct tcpiphdr *ti; + struct mbuf *m; + struct tcpiphdr *ti; u_char opt[MAX_TCPOPTLEN]; unsigned optlen, hdrlen; int idle, sendalot; Modified: trunk/vde-2/src/slirpvde/tcp_subr.c =================================================================== --- trunk/vde-2/src/slirpvde/tcp_subr.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/tcp_subr.c 2014-10-12 20:17:24 UTC (rev 582) @@ -66,7 +66,7 @@ tcp_template(struct tcpcb *tp) { struct socket *so = tp->t_socket; - register struct tcpiphdr *n = &tp->t_template; + struct tcpiphdr *n = &tp->t_template; n->ti_mbuf = NULL; n->ti_x1 = 0; @@ -104,7 +104,7 @@ tcp_respond(struct tcpcb *tp, struct tcpiphdr *ti, struct mbuf *m, tcp_seq ack, tcp_seq seq, int flags) { - register int tlen; + int tlen; int win = 0; DEBUG_CALL("tcp_respond"); @@ -175,7 +175,7 @@ struct tcpcb * tcp_newtcpcb(struct socket *so) { - register struct tcpcb *tp; + struct tcpcb *tp; tp = (struct tcpcb *)malloc(sizeof(*tp)); if (tp == NULL) @@ -237,10 +237,10 @@ struct tcpcb * tcp_close(struct tcpcb *tp) { - register struct tcpiphdr *t; + struct tcpiphdr *t; struct socket *so = tp->t_socket; Slirp *slirp = so->slirp; - register struct mbuf *m; + struct mbuf *m; DEBUG_CALL("tcp_close"); DEBUG_ARG("tp = %lx", (long )tp); Modified: trunk/vde-2/src/slirpvde/tcp_timer.c =================================================================== --- trunk/vde-2/src/slirpvde/tcp_timer.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/tcp_timer.c 2014-10-12 20:17:24 UTC (rev 582) @@ -32,7 +32,7 @@ #include <slirp.h> -static struct tcpcb *tcp_timers(register struct tcpcb *tp, int timer); +static struct tcpcb *tcp_timers(struct tcpcb *tp, int timer); /* * Fast timeout routine for processing delayed acks @@ -40,8 +40,8 @@ void tcp_fasttimo(Slirp *slirp) { - register struct socket *so; - register struct tcpcb *tp; + struct socket *so; + struct tcpcb *tp; DEBUG_CALL("tcp_fasttimo"); @@ -64,9 +64,9 @@ void tcp_slowtimo(Slirp *slirp) { - register struct socket *ip, *ipnxt; - register struct tcpcb *tp; - register int i; + struct socket *ip, *ipnxt; + struct tcpcb *tp; + int i; DEBUG_CALL("tcp_slowtimo"); @@ -106,7 +106,7 @@ void tcp_canceltimers(struct tcpcb *tp) { - register int i; + int i; for (i = 0; i < TCPT_NTIMERS; i++) tp->t_timer[i] = 0; @@ -119,9 +119,9 @@ * TCP timer processing. */ static struct tcpcb * -tcp_timers(register struct tcpcb *tp, int timer) +tcp_timers(struct tcpcb *tp, int timer) { - register int rexmt; + int rexmt; DEBUG_CALL("tcp_timers"); Modified: trunk/vde-2/src/slirpvde/udp.c =================================================================== --- trunk/vde-2/src/slirpvde/udp.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/udp.c 2014-10-12 20:17:24 UTC (rev 582) @@ -54,11 +54,11 @@ * ip->ip_len length data (IPDU) */ void -udp_input(register struct mbuf *m, int iphlen) +udp_input(struct mbuf *m, int iphlen) { Slirp *slirp = m->slirp; - register struct ip *ip; - register struct udphdr *uh; + struct ip *ip; + struct udphdr *uh; int len; struct ip save_ip; struct socket *so; @@ -232,7 +232,7 @@ struct sockaddr_in *saddr, struct sockaddr_in *daddr, int iptos) { - register struct udpiphdr *ui; + struct udpiphdr *ui; int error = 0; DEBUG_CALL("udp_output"); Modified: trunk/vde-2/src/slirpvde/udp.h =================================================================== --- trunk/vde-2/src/slirpvde/udp.h 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/slirpvde/udp.h 2014-10-12 20:17:24 UTC (rev 582) @@ -74,7 +74,7 @@ struct mbuf; void udp_init(Slirp *); -void udp_input(register struct mbuf *, int); +void udp_input(struct mbuf *, int); int udp_output(struct socket *, struct mbuf *, struct sockaddr_in *); int udp_attach(struct socket *); void udp_detach(struct socket *); Modified: trunk/vde-2/src/vde_autolink.c =================================================================== --- trunk/vde-2/src/vde_autolink.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_autolink.c 2014-10-12 20:17:24 UTC (rev 582) @@ -1454,7 +1454,7 @@ npfd=newmgmtconn(pfd[mgmtindex].fd,pfd,npfd); if (mgmt && (npfd > mgmtindex+1)) { - register int i; + int i; for (i=mgmtindex+1;i<npfd;i++) { if( (pfd[i].revents & POLLHUP) || ((pfd[i].revents & POLLIN) && Modified: trunk/vde-2/src/vde_cryptcab/crc32.c =================================================================== --- trunk/vde-2/src/vde_cryptcab/crc32.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_cryptcab/crc32.c 2014-10-12 20:17:24 UTC (rev 582) @@ -33,7 +33,7 @@ */ u_int32_t chksum_crc32 (unsigned char *block, unsigned int length) { - register unsigned long crc; + unsigned long crc; unsigned long i; crc = 0xFFFFFFFF; @@ -47,7 +47,7 @@ unsigned char *crc32(unsigned char *block, unsigned int len) { - register unsigned long crc=chksum_crc32(block,len); + unsigned long crc=chksum_crc32(block,len); unsigned char *res=malloc(4); res[0]=crc&0x000000FF; Modified: trunk/vde-2/src/vde_l3/vde_l3.c =================================================================== --- trunk/vde-2/src/vde_l3/vde_l3.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_l3/vde_l3.c 2014-10-12 20:17:24 UTC (rev 582) @@ -1513,7 +1513,7 @@ mgmtfdstart=mgmtindex+1; } if (mgmtfdstart >= 0 && npfd > mgmtfdstart) { - register int i; + int i; for (i=mgmtfdstart;i<npfd;i++) { if (pfd[i].revents & POLLHUP || (pfd[i].revents & POLLIN && mgmtcommand(pfd[i].fd) < 0)) Modified: trunk/vde-2/src/vde_plug.c =================================================================== --- trunk/vde-2/src/vde_plug.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_plug.c 2014-10-12 20:17:24 UTC (rev 582) @@ -130,7 +130,7 @@ static void vde_ip_check(const unsigned char *buf,int rnx) { struct header *ph=(struct header *) buf; - register int i,j,vlan=0; + int i,j,vlan=0; char addr[256]; union body *pb; @@ -286,7 +286,7 @@ int main(int argc, char **argv) { static char *sockname=NULL; - register ssize_t nx; + ssize_t nx; struct vde_open_args open_args={.port=0,.group=NULL,.mode=0700}; uname(&me); Modified: trunk/vde-2/src/vde_router/rbtree.c =================================================================== --- trunk/vde-2/src/vde_router/rbtree.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_router/rbtree.c 2014-10-12 20:17:24 UTC (rev 582) @@ -79,7 +79,7 @@ if (parent == gparent->rb_left) { { - register struct rb_node *uncle = gparent->rb_right; + struct rb_node *uncle = gparent->rb_right; if (uncle && rb_is_red(uncle)) { rb_set_black(uncle); @@ -92,7 +92,7 @@ if (parent->rb_right == node) { - register struct rb_node *tmp; + struct rb_node *tmp; __rb_rotate_left(parent, root); tmp = parent; parent = node; @@ -104,7 +104,7 @@ __rb_rotate_right(gparent, root); } else { { - register struct rb_node *uncle = gparent->rb_left; + struct rb_node *uncle = gparent->rb_left; if (uncle && rb_is_red(uncle)) { rb_set_black(uncle); @@ -117,7 +117,7 @@ if (parent->rb_left == node) { - register struct rb_node *tmp; + struct rb_node *tmp; __rb_rotate_right(parent, root); tmp = parent; parent = node; Modified: trunk/vde-2/src/vde_switch/bitarray.h =================================================================== --- trunk/vde-2/src/vde_switch/bitarray.h 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/bitarray.h 2014-10-12 20:17:24 UTC (rev 582) @@ -94,7 +94,7 @@ static inline bitarray ba_realloc(bitarray b,int n,int m) { - register int __i; + int __i; bitarray nb=realloc(b,__WORDSIZEROUND(m)*sizeof(unsigned long)); if(nb != NULL) for(__i=__WORDSIZEROUND(n);__i<__WORDSIZEROUND(m);__i++) @@ -120,15 +120,15 @@ static inline void ba_zap(bitarray x,int n) { - register unsigned int __i; + unsigned int __i; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) x[__i]=0; } #define ba_FORALLFUN(X,N,F,ARG) \ - ({ register unsigned int __i,__j; \ - register bitarrayelem __v; \ + ({ unsigned int __i,__j; \ + bitarrayelem __v; \ int max=__WORDSIZEROUND(N); \ for (__i=0; __i< max; __i++) \ for (__v=(X)[__i],__j=0; __j < __VDEWORDSIZE; __v >>=1, __j++) \ @@ -136,8 +136,8 @@ 0; }) #define ba_FORALL(X,N,EXPR,K) \ - ({ register unsigned int __i,__j; \ - register bitarrayelem __v; \ + ({ unsigned int __i,__j; \ + bitarrayelem __v; \ int max=__WORDSIZEROUND(N); \ for (__i=0; __i< max; __i++) \ for (__v=(X)[__i],__j=0; __j < __VDEWORDSIZE; __v >>=1, __j++) \ @@ -146,8 +146,8 @@ static inline int ba_card(bitarray x,int n) { - register unsigned int __i,__j,__n=0; - register bitarrayelem __v; + unsigned int __i,__j,__n=0; + bitarrayelem __v; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) for (__v=(x)[__i],__j=0; __j < __VDEWORDSIZE; __v >>=1, __j++) @@ -157,8 +157,8 @@ static inline void ba_empty(bitarray x,int n) { - register unsigned int __i; - register bitarrayelem __v=0; + unsigned int __i; + bitarrayelem __v=0; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) __v |= (x)[__i]; \ @@ -171,7 +171,7 @@ static inline void ba_add(bitarray dst, bitarray src, int n) { - register unsigned int __i; + unsigned int __i; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) dst[__i] |= src[__i]; @@ -179,7 +179,7 @@ static inline void ba_remove(bitarray dst, bitarray src, int n) { - register unsigned int __i; + unsigned int __i; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) dst[__i] &= ~(src[__i]); @@ -187,7 +187,7 @@ static inline void ba_negate(bitarray x, int n) { - register unsigned int __i; + unsigned int __i; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) x[__i] = ~(x[__i]); @@ -203,8 +203,8 @@ static inline bitarray bac_realloc(bitarray b,int n,int m) { - register int __i; - register int __size=b[__WORDSIZEROUND(n)]; + int __i; + int __size=b[__WORDSIZEROUND(n)]; bitarray nb=realloc(b,(__WORDSIZEROUND(m)+1)*sizeof(unsigned long)); if(nb != NULL) { b[__WORDSIZEROUND(m)]=__size; @@ -223,23 +223,23 @@ static inline void bac_set(bitarray x,int n,int i) { - register bitarrayelem __v=x[i>>__LOG_WORDSIZE]; - register bitarrayelem __w=__v; + bitarrayelem __v=x[i>>__LOG_WORDSIZE]; + bitarrayelem __w=__v; __v |= (1L << (i & __WORDSIZEMASK)); if (__v != __w) x[i>>__LOG_WORDSIZE]=__v,(x[__WORDSIZEROUND(n)]++); } static inline void bac_clr(bitarray x,int n,int i) { - register bitarrayelem __v=x[i>>__LOG_WORDSIZE]; - register bitarrayelem __w=__v; + bitarrayelem __v=x[i>>__LOG_WORDSIZE]; + bitarrayelem __w=__v; __v &= ~(1L << (i & __WORDSIZEMASK)); if (__v != __w) x[i>>__LOG_WORDSIZE]=__v,(x[__WORDSIZEROUND(n)]--); } static inline void bac_zap(bitarray x,int n) { - register unsigned int __i; + unsigned int __i; int max=__WORDSIZEROUND(n); for (__i=0; __i< max; __i++) x[__i]=0; @@ -247,18 +247,18 @@ } #define bac_FORALLFUN(X,N,F,ARG) \ - ({ register unsigned int __i,__j; \ - register bitarrayelem __v; \ - register int __n=(X)[__WORDSIZEROUND(N)]; \ + ({ unsigned int __i,__j; \ + bitarrayelem __v; \ + int __n=(X)[__WORDSIZEROUND(N)]; \ for (__i=0; __n > 0; __i++) \ for (__v=(X)[__i],__j=0; __j < __VDEWORDSIZE; __v >>=1, __j++) \ if (__v & 1) (F)(__i*__VDEWORDSIZE+__j,(ARG)),__n--; \ 0; }) #define bac_FORALL(X,N,EXPR,K) \ - ({ register unsigned int __i,__j; \ - register bitarrayelem __v; \ - register int __n=(X)[__WORDSIZEROUND(N)]; \ + ({ unsigned int __i,__j; \ + bitarrayelem __v; \ + int __n=(X)[__WORDSIZEROUND(N)]; \ for (__i=0; __n > 0; __i++) \ for (__v=(X)[__i],__j=0; __j < __VDEWORDSIZE; __v >>=1, __j++) \ if (__v & 1) (K)=__i*__VDEWORDSIZE+__j,(EXPR),__n--; \ Modified: trunk/vde-2/src/vde_switch/consmgmt.c =================================================================== --- trunk/vde-2/src/vde_switch/consmgmt.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/consmgmt.c 2014-10-12 20:17:24 UTC (rev 582) @@ -79,7 +79,7 @@ void addcl(int ncl,struct comlist *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { cl->next=NULL; (*clt)=cl; @@ -89,9 +89,9 @@ void delcl(int ncl,struct comlist *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { - register struct comlist **p=&clh; + struct comlist **p=&clh; while (*p != NULL) { if (*p == cl) *p=cl->next; @@ -116,9 +116,9 @@ void deldbgcl(int ncl,struct dbgcl *cl) { - register int i; + int i; for (i=0;i<ncl;i++,cl++) { - register struct dbgcl **p=&dbgclh; + struct dbgcl **p=&dbgclh; while (*p != NULL) { if (*p == cl) { if (cl->fds) free(cl->fds); @@ -143,7 +143,7 @@ void delplugin(struct plugin *cl) { - register struct plugin **p=plugint=&pluginh; + struct plugin **p=plugint=&pluginh; while (*p != NULL) { if (*p == cl) *p=cl->next; Modified: trunk/vde-2/src/vde_switch/fstp.c =================================================================== --- trunk/vde-2/src/vde_switch/fstp.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/fstp.c 2014-10-12 20:17:24 UTC (rev 582) @@ -192,7 +192,7 @@ int fstnewvlan(int vlan) { /*printf("F new vlan %d\n",vlan);*/ - register unsigned int port; + unsigned int port; int newvlan=(fsttab[vlan] == NULL); if (newvlan && ((fsttab[vlan]=malloc(sizeof(struct vlst))) == NULL || @@ -249,7 +249,7 @@ void fstsetnumports (int val) { - register int i; + int i; /*printf("F numports %d\n",val);*/ for (i=0;i<NUMOFVLAN;i++) { if (fsttab[i]) { @@ -292,7 +292,7 @@ static void fst_hello_vlan(int vlan,int now) { int age,nowvlan; - register int port; + int port; /* timeout on the root port */ if (fsttab[vlan]->rootport != 0 && (now - fsttab[vlan]->roottimestamp) > 3*helloperiod) fstnewvlan(vlan); @@ -333,7 +333,7 @@ */ static void fst_updatebackup(int vlan,int index) { - register int port; + int port; ba_FORALL(fsttab[vlan]->backup,numports, ({ if (!FSTP_ACTIVE(vlan,port)) { ba_clr(fsttab[vlan]->backup,port); @@ -413,7 +413,7 @@ */ static void topology_change(int vlan, int genport) { - register int port; + int port; int now=qtime(); //if (now - fsttab[vlan]->tctime > 2*helloperiod) { /*limit age?*/ /*printf("TOPOLOGY CHANGE %d\n",vlan);*/ @@ -438,7 +438,7 @@ * 3- give back the acknowledge and put the new root in fwd*/ static void fastprotocol(int vlan, int newrootport) { - register int port; + int port; ba_FORALL(fsttab[vlan]->untag,numports, ({ if(port != newrootport && !(ba_check(fsttab[vlan]->backup,port)) && !(ba_check(fsttab[vlan]->edge,port)) && FSTP_ACTIVE(vlan,port)) { @@ -667,7 +667,7 @@ static void fstprintactive(int vlan,FILE *fd) { - register int i; + int i; printoutc(fd,"FST DATA VLAN %04d %s %s",vlan, memcmp(myid,fsttab[vlan]->root,SWITCHID_LEN)==0?"ROOTSWITCH":"", ((pflag & FSTP_TAG)==0)?"FSTP IS DISABLED":""); @@ -690,7 +690,7 @@ static int fstprint(FILE *fd,char *arg) { if (*arg != 0) { - register int vlan; + int vlan; vlan=atoi(arg); if (vlan >= 0 && vlan < NUMOFVLAN-1) { if (bac_check(validvlan,vlan)) Modified: trunk/vde-2/src/vde_switch/hash.c =================================================================== --- trunk/vde-2/src/vde_switch/hash.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/hash.c 2014-10-12 20:17:24 UTC (rev 582) @@ -285,8 +285,8 @@ if (vx == 0) return 0; else { - register int i=0; - register int x=vx-1; + int i=0; + int x=vx-1; while (x) { x>>=1; i++; } if (vx != 1<<i) printlog(LOG_WARNING,"Hash size must be a power of 2. %d rounded to %d",vx,1<<i); @@ -352,7 +352,7 @@ if (rv < 6) return EINVAL; else { - register int i; + int i; for (i=0;i<ETH_ALEN;i++) mac[i]=maci[i]; e=find_entry(extmac(mac,vlan)); Modified: trunk/vde-2/src/vde_switch/port.c =================================================================== --- trunk/vde-2/src/vde_switch/port.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/port.c 2014-10-12 20:17:24 UTC (rev 582) @@ -65,7 +65,7 @@ /* void packet_dump (struct packet *p) { - register int i; + int i; printf ("packet dump dst"); for (i=0;i<ETH_ALEN;i++) printf(":%02x",p->header.dest[i]); @@ -180,7 +180,7 @@ struct port *port=portv[portno]; if (port != NULL && port->ep==NULL) { portv[portno]=NULL; - register int i; + int i; /* delete completely the port. all vlan defs zapped */ bac_FORALL(validvlan,NUMOFVLAN,ba_clr(vlant[i].table,portno),i); free(port); @@ -268,7 +268,7 @@ ep->vdepq_max=stdqlen; #endif if(port->ep == NULL) {/* WAS INACTIVE */ - register int i; + int i; /* copy all the vlan defs to the active vlan defs */ ep->next=port->ep; port->ep=ep; @@ -351,7 +351,7 @@ port->ms=NULL; port->sender=NULL; port->curuser=-1; - register int i; + int i; /* inactivate port: all active vlan defs cleared */ bac_FORALL(validvlan,NUMOFVLAN,({ ba_clr(vlant[i].bctag,portno); @@ -467,7 +467,7 @@ void portset_send_packet(bitarray portset, void *packet, int len) { - register int i; + int i; #ifndef VDE_PQ2 ba_FORALL(portset,numports, SEND_PACKET_PORT(portv[i],i,packet,len), i); @@ -590,7 +590,7 @@ portv[port]->bytesin+=len; #endif if (pflag & HUB_TAG) { /* this is a HUB */ - register int i; + int i; #ifndef VDE_PQ2 for(i = 1; i < numports; i++) if((i != port) && (portv[i] != NULL)) @@ -640,7 +640,7 @@ /* BROADCAST: tag/untag. Broadcast the packet untouched on the ports * of the same tag-ness, then transform it to the other tag-ness for the others*/ if (tagged) { - register int i; + int i; #ifndef VDE_PQ2 ba_FORALL(vlant[vlan].bctag,numports, ({if (i != port) SEND_PACKET_PORT(portv[i],i,packet,len);}),i); @@ -657,7 +657,7 @@ ({if (i != port) SEND_PACKET_PORT(portv[i],i,packet,len,&tmpbufu);}),i); #endif } else { /* untagged */ - register int i; + int i; #ifndef VDE_PQ2 ba_FORALL(vlant[vlan].bcuntag,numports, ({if (i != port) SEND_PACKET_PORT(portv[i],i,packet,len);}),i); @@ -989,7 +989,7 @@ static int print_ptable(FILE *fd,char *arg) { - register int i; + int i; if (*arg != 0) { i=atoi(arg); if (i <0 || i>=numports) @@ -1006,7 +1006,7 @@ static int print_ptableall(FILE *fd,char *arg) { - register int i; + int i; if (*arg != 0) { i=atoi(arg); if (i <0 || i>=numports) @@ -1034,7 +1034,7 @@ static int portresetcounters(char *arg) { - register int i; + int i; if (*arg != 0) { i=atoi(arg); if (i <0 || i>=numports) @@ -1131,7 +1131,7 @@ { if (vlan >= 0 && vlan < NUMOFVLAN) { if (bac_check(validvlan,vlan)) { - register int i,used=0; + int i,used=0; ba_FORALL(vlant[vlan].table,numports,used++,i); if (used) return EADDRINUSE; @@ -1206,7 +1206,7 @@ static void vlanprintactive(int vlan,FILE *fd) { - register int i; + int i; printoutc(fd,"VLAN %04d",vlan); #ifdef FSTP if (pflag & FSTP_TAG) { @@ -1248,7 +1248,7 @@ static int vlanprint(FILE *fd,char *arg) { if (*arg != 0) { - register int vlan; + int vlan; vlan=atoi(arg); if (vlan >= 0 && vlan < NUMOFVLAN-1) { if (bac_check(validvlan,vlan)) @@ -1264,7 +1264,7 @@ static void vlanprintelem(int vlan,FILE *fd) { - register int i; + int i; printoutc(fd,"VLAN %04d",vlan); ba_FORALL(vlant[vlan].table,numports, printoutc(fd," -- Port %04d tagged=%d active=%d status=%s", @@ -1274,7 +1274,7 @@ static int vlanprintall(FILE *fd,char *arg) { if (*arg != 0) { - register int vlan; + int vlan; vlan=atoi(arg); if (vlan > 0 && vlan < NUMOFVLAN-1) { if (bac_check(validvlan,vlan)) @@ -1302,7 +1302,7 @@ if (rv < 6) return EINVAL; else { - register int i; + int i; for (i=0;i<ETH_ALEN;i++) switchmac[i]=maci[i]; return 0; Modified: trunk/vde-2/src/vde_switch/qtimer.c =================================================================== --- trunk/vde-2/src/vde_switch/qtimer.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/qtimer.c 2014-10-12 20:17:24 UTC (rev 582) @@ -57,7 +57,7 @@ unsigned int qtimer_add(time_t period,int times,void (*call)(),void *arg) { - register int n; + int n; if (period>0 && call && times>=0) { qtime_csenter(); if (activeqt >= maxqt) { @@ -96,7 +96,7 @@ void qtimer_del(unsigned int n) { - register int i; + int i; for (i=0; i<activeqt; i++) { if (n==qth[i]->qt_n) { qth[i]->qt_times=0; @@ -107,8 +107,8 @@ static void sig_alarm(int sig) { - register int i; - register int j; + int i; + int j; gqtime++; //printf("%d\n",gqtime); for (i=0,j=0; i<activeqt; i++) { Modified: trunk/vde-2/src/vde_switch/vde_switch.c =================================================================== --- trunk/vde-2/src/vde_switch/vde_switch.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_switch/vde_switch.c 2014-10-12 20:17:24 UTC (rev 582) @@ -115,7 +115,7 @@ unsigned char add_type(struct swmodule *mgr,int prio) { - register int i; + int i; if(ntypes==maxtypes) { maxtypes = maxtypes ? 2 * maxtypes : 8; if (maxtypes > PRIOFLAG) { @@ -190,14 +190,14 @@ static void file_cleanup(void) { - register int i; + int i; for(i = 0; i < nfds; i++) TYPE2MGR(fdpp[i]->type)->cleanup(fdpp[i]->type,fds[i].fd,fdpp[i]->private_data); } void remove_fd(int fd) { - register int i; + int i; for(i = 0; i < nfds; i++){ if(fds[i].fd == fd) break; @@ -267,7 +267,7 @@ static void main_loop() { time_t now; - register int n,i; + int n,i; while(1) { n=poll(fds,nfds,-1); now=qtime(); @@ -277,7 +277,7 @@ } else { for(i = 0; /*i < nfds &&*/ n>0; i++){ if(fds[i].revents != 0) { - register int prenfds=nfds; + int prenfds=nfds; n--; fdpp[i]->timestamp=now; TYPE2MGR(fdpp[i]->type)->handle_io(fdpp[i]->type,fds[i].fd,fds[i].revents,fdpp[i]->private_data); @@ -289,7 +289,7 @@ else { if (i < nfds && i > 0 && i != nprio) { - register int i_1=i-1; + int i_1=i-1; if (fdpp[i]->timestamp > fdpp[i_1]->timestamp) { struct pollfd tfds; struct pollplus *tfdpp; @@ -356,7 +356,7 @@ static struct option *optcpy(struct option *tgt, struct option *src, int n, int tag) { - register int i; + int i; memcpy(tgt,src,sizeof(struct option) * n); for (i=0;i<n;i++) { tgt[i].val=(tgt[i].val & 0xffff) | tag << 16; @@ -399,7 +399,7 @@ Usage(); } else { - register int i; + int i; for (i=0;i<ETH_ALEN;i++) switchmac[i]=maci[i]; } @@ -451,7 +451,7 @@ if (long_options == NULL || optstring==NULL) exit(2); { /* fill-in the long_options fields */ - register int i; + int i; char *os=optstring; char last=0; struct option *opp=long_options; @@ -581,7 +581,7 @@ { struct timeval v; long val; - register int i; + int i; gettimeofday(&v,NULL); srand48(v.tv_sec ^ v.tv_usec ^ getpid()); for(i=0,val=lrand48();i<4; i++,val>>=8) Modified: trunk/vde-2/src/vde_vxlan/vxlan_hash.c =================================================================== --- trunk/vde-2/src/vde_vxlan/vxlan_hash.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vde_vxlan/vxlan_hash.c 2014-10-12 20:17:24 UTC (rev 582) @@ -207,8 +207,8 @@ if (vx == 0) return 0; else { - register int i=0; - register int x=vx-1; + int i=0; + int x=vx-1; while (x) { x>>=1; i++; } if (vx != 1<<i) printlog(LOG_WARNING,"Hash size must be a power of 2. %d rounded to %d",vx,1<<i); Modified: trunk/vde-2/src/vdeq.c =================================================================== --- trunk/vde-2/src/vdeq.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vdeq.c 2014-10-12 20:17:24 UTC (rev 582) @@ -45,7 +45,7 @@ static int countnics(const char *s) { - register int nics=1; + int nics=1; while (*s) { if (*s==',') nics++; s++; @@ -55,8 +55,8 @@ static int countnewnics(int argc,char *argv[]) { - register int nics=0; - register int netflag=0; + int nics=0; + int netflag=0; while (argc > 0) { if (strcmp(argv[0],"-net")==0) netflag=1; @@ -73,7 +73,7 @@ static int isdaemonize(int argc,char *argv[]) { - register int daemonize=0; + int daemonize=0; if(strcmp(filename,"qemu")==0){ int daemonadds=0; while (argc > 0) { @@ -120,7 +120,7 @@ static void cleanup() { - register int i; + int i; for (i=0; i<nb_nics; i++) { if (conn[i] != NULL) vde_close(conn[i]); @@ -282,13 +282,13 @@ char *argsock=NULL,**sockname; int *ports; int result; - register ssize_t nx; + ssize_t nx; int newargc; int daemonize; char **newargv; typedef int pair[2]; pair *sp; - register int i,j; + int i,j; int oldsyntax=0; int newsyntax=0; int ver; @@ -415,8 +415,8 @@ sockname[0]=NULL; else { - register char *s=argsock; - register char oldch; + char *s=argsock; + char oldch; i=0; do { sockname[i++]=s; Modified: trunk/vde-2/src/vdetaplib/libvdetap.c =================================================================== --- trunk/vde-2/src/vdetaplib/libvdetap.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vdetaplib/libvdetap.c 2014-10-12 20:17:24 UTC (rev 582) @@ -84,7 +84,7 @@ void libvdetap_init (void) __attribute((constructor)); void libvdetap_init(void) { - register int i; + int i; nativesym(ioctl, "ioctl"); nativesym(open, "open"); nativesym(open64, "open64"); Modified: trunk/vde-2/src/vdetaplib/vdetap.c =================================================================== --- trunk/vde-2/src/vdetaplib/vdetap.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/vdetaplib/vdetap.c 2014-10-12 20:17:24 UTC (rev 582) @@ -30,7 +30,7 @@ { int fd,fddata; int nx; - register int i; + int i; struct vde_open_args open_args={.port=0,.group=NULL,.mode=0700}; char *descr; /*printf("argc = %d\n",argc); Modified: trunk/vde-2/src/wirefilter.c =================================================================== --- trunk/vde-2/src/wirefilter.c 2014-10-12 20:05:22 UTC (rev 581) +++ trunk/vde-2/src/wirefilter.c 2014-10-12 20:17:24 UTC (rev 582) @@ -670,7 +670,7 @@ //fprintf(stderr,"%s: splitpacket rnx=%d remaining=%d size=%d\n",progname,rnx[dir],remaining[dir],size); if (size==0) return; if (rnx[dir]>0) { - register int amount=MIN(remaining[dir],size); + int amount=MIN(remaining[dir],size); //fprintf(stderr,"%s: fragment amount %d\n",progname,amount); memcpy(fragp[dir],buf,amount); remaining[dir]-=amount; @@ -1679,7 +1679,7 @@ int mgmtfdstart=consoleindex; if (mgmtindex >= 0) mgmtfdstart=mgmtindex+1; if (mgmtfdstart >= 0 && npfd > mgmtfdstart) { - register int i; + int i; for (i=mgmtfdstart;i<npfd;i++) { if (pfd[i].revents & POLLIN && mgmtcommand(pfd[i].fd) < 0) pfd[i].revents |= POLLHUP; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer http://p.sf.net/sfu/Zoho _______________________________________________ vde-users mailing list vde-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/vde-users