Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/net Fix weird hardware address assignment that GCC 4.5 c...



details:   https://anonhg.NetBSD.org/src/rev/4c8deffab785
branches:  trunk
changeset: 767483:4c8deffab785
user:      tron <tron%NetBSD.org@localhost>
date:      Tue Jul 19 19:42:27 2011 +0000

description:
Fix weird hardware address assignment that GCC 4.5 complains about.

diffstat:

 sys/net/if_tokensubr.c |  10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)

diffs (31 lines):

diff -r eb2c7d5dd440 -r 4c8deffab785 sys/net/if_tokensubr.c
--- a/sys/net/if_tokensubr.c    Tue Jul 19 19:19:39 2011 +0000
+++ b/sys/net/if_tokensubr.c    Tue Jul 19 19:42:27 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_tokensubr.c,v 1.60 2010/04/05 07:22:24 joerg Exp $  */
+/*     $NetBSD: if_tokensubr.c,v 1.61 2011/07/19 19:42:27 tron Exp $   */
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -92,7 +92,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_tokensubr.c,v 1.60 2010/04/05 07:22:24 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_tokensubr.c,v 1.61 2011/07/19 19:42:27 tron Exp $");
 
 #include "opt_inet.h"
 #include "opt_atalk.h"
@@ -597,10 +597,8 @@
                        sa.sa_len = sizeof(sa);
                        eh = (struct ether_header *)sa.sa_data;
                        for (i = 0; i < ISO88025_ADDR_LEN; i++) {
-                               eh->ether_shost[i] = c = trh->token_dhost[i];
-                               eh->ether_dhost[i] =
-                                   eh->ether_dhost[i] = trh->token_shost[i];
-                               eh->ether_shost[i] = c;
+                               eh->ether_shost[i] = trh->token_dhost[i];
+                               eh->ether_dhost[i] = trh->token_shost[i];
                        }
                        eh->ether_type = 0;
                        m_adj(m, lan_hdr_len);



Home | Main Index | Thread Index | Old Index