NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
port-x68k/50759: [src/sys/arch/x68k/dev/zs.c:159]: (error) Array 'zs_physaddr[5]' accessed at index 5, which is out of bounds.
>Number: 50759
>Category: port-x68k
>Synopsis: [src/sys/arch/x68k/dev/zs.c:159]: (error) Array 'zs_physaddr[5]' accessed at index 5, which is out of bounds.
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: port-x68k-maintainer
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Feb 03 10:25:00 +0000 2016
>Originator: David Binderman
>Release: cvs dated 20160203
>Organization:
>Environment:
>Description:
Source code is
for (i = 0; i < ZS_MAXDEV; i++)
if (zsaddr == (void *)zs_physaddr[i]) /* XXX */
break;
/* ... */
if (zsaddr != (void *)zs_physaddr[i])
return 0;
Maybe better code
for (i = 0; i < ZS_MAXDEV; i++)
if (zsaddr == (void *)zs_physaddr[i]) /* XXX */
break;
/* ... */
if (i >= ZS_MAXDEV)
return 0;
>How-To-Repeat:
>Fix:
Home |
Main Index |
Thread Index |
Old Index