NetBSD-Bugs archive

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

kern/50536: src/sys/dev/pci/n8/common/api/n8_key_works.c:142: possible bad size ?



>Number:         50536
>Category:       kern
>Synopsis:       src/sys/dev/pci/n8/common/api/n8_key_works.c:142: possible bad size ?
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Dec 11 10:55:01 +0000 2015
>Originator:     David Binderman
>Release:        cvs dated 20151210
>Organization:
>Environment:
>Description:

[src/sys/dev/pci/n8/common/api/n8_key_works.c:142]: (warning) Size of pointer 'key_p' used instead of size of its data.

      if (memcmp(weak_keys[i], key_p, sizeof(key_p)) == 0)

maybe better code

      if (memcmp(weak_keys[i], key_p, sizeof(*key_p)) == 0)

>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index