--- projects/libstatgrab/src/libstatgrab/network_stats.c 2006/10/09 17:25:06 1.80 +++ projects/libstatgrab/src/libstatgrab/network_stats.c 2010/06/09 14:44:28 1.81 @@ -18,7 +18,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA * 02111-1307 USA * - * $Id: network_stats.c,v 1.80 2006/10/09 17:25:06 tdb Exp $ + * $Id: network_stats.c,v 1.81 2010/06/09 14:44:28 tdb Exp $ */ #ifdef HAVE_CONFIG_H @@ -607,8 +607,8 @@ sg_network_iface_stats *sg_get_network_iface_stats(int continue; } - /* Only intrested in the first 4 bits) - Assuming only ETHER devices */ - x = ifmed.ifm_active & 0x0f; + /* Assuming only ETHER devices */ + x = IFM_SUBTYPE(ifmed.ifm_active); switch(x){ /* 10 Mbit connections. Speedy :) */ case(IFM_10_T): @@ -618,7 +618,7 @@ sg_network_iface_stats *sg_get_network_iface_stats(int case(IFM_10_FL): network_iface_stat_ptr->speed = 10; break; - /* 100 Mbit conneections */ + /* 100 Mbit connections */ case(IFM_100_TX): case(IFM_100_FX): case(IFM_100_T4):