NetBSD-Bugs archive

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

port-i386/50668: src/sys/arch/i386/stand/lib/netif/3c90xb.c:349: broken error checking ?



>Number:         50668
>Category:       port-i386
>Synopsis:       src/sys/arch/i386/stand/lib/netif/3c90xb.c:349: broken error checking ?
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    port-i386-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Jan 17 09:40:00 +0000 2016
>Originator:     David Binderman
>Release:        cvs dated 20160116
>Organization:
>Environment:
>Description:
[src/sys/arch/i386/stand/lib/netif/3c90xb.c:349]: (style) Checking if unsigned variable 'ether_medium' is less than zero.

        ex_probemedia();
        if (ether_medium < 0)
            return 0;

Maybe better code

        ex_probemedia();
        if (ether_medium == (unsigned int) -1)
            return 0;

>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index