Date: Tue, 11 Nov 2008 21:17:58 GMT From: Adam Morrison <adamx@tau.ac.il> To: freebsd-gnats-submit@FreeBSD.org Subject: kern/128801: Bug in if_bce.c:bce_get_media() Message-ID: <200811112117.mABLHwSA075995@www.freebsd.org> Resent-Message-ID: <200811112120.mABLK1SJ025739@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 128801 >Category: kern >Synopsis: Bug in if_bce.c:bce_get_media() >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Nov 11 21:20:01 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Adam Morrison >Release: HEAD >Organization: >Environment: >Description: There is a bug in if_bce.c:bce_get_media() when checking for SerDes: if (sc->bce_phy_flags && BCE_PHY_SERDES_FLAG) { Note "&&" instead of "&". The way the code is structured everything works out fine because ->bce_phys_flags will be true iff BCE_PHY_SERDES_FLAG is set. Still, this is confusing and is a potential error waiting to happen. >How-To-Repeat: >Fix: "&&" -> "&" >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200811112117.mABLHwSA075995>