[Bug 204253] usr/src/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_partition_tbl.c:319: bad if test ?

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Nov 3 15:31:48 UTC 2015


            Bug ID: 204253
           Summary: usr/src/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_p
                    artition_tbl.c:319: bad if test ?
           Product: Base System
           Version: 11.0-CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: misc
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: dcb314 at hotmail.com

(warning) Char literal compared with pointer 'chunk_name'. Did you intend to
dereference it?

Source code is

    if (chunk_name == NULL || chunk_name == '\0')

Maybe better code

    if (chunk_name == NULL || chunk_name[0] == '\0')

You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-bugs mailing list