NetBSD-Bugs archive

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

Re: bin/50757: src/usr.sbin/sysinst/arch/mac68k/md.c: 2 * array index out of range ?



The following reply was made to PR bin/50757; it has been noted by GNATS.

From: David Holland <dholland-bugs%netbsd.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: 
Subject: Re: bin/50757: src/usr.sbin/sysinst/arch/mac68k/md.c: 2 * array
 index out of range ?
Date: Tue, 31 May 2016 02:50:37 +0000

 On Wed, Feb 03, 2016 at 10:05:00AM +0000, dcb314%hotmail.com@localhost wrote:
  > Source code is
  > 
  >    for (i=0;i<NEW_MAP_SIZE;i++) {
  >        if (i > 0)
  >         new_map[i].pmPyPartStart = new_map[i-1].pmPyPartStart +
  >             new_map[i-1].pmPartBlkCnt;
  >        new_map[i].pmDataCnt = new_map[i].pmPartBlkCnt;
  > 
  > but
  > 
  > src/usr.sbin/sysinst/arch/mac68k/md.h:#define NEW_MAP_SIZE 15
  > 
  > and new_map only seems to have six elements in it.
 
 I have disabled the offending code (which computes information that is
 not subsequently used) but someone with platform knowledge is needed
 to fix it properly.
 
 -- 
 David A. Holland
 dholland%netbsd.org@localhost
 


Home | Main Index | Thread Index | Old Index