NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: bin/50965: src/usr.bin/sort/msort.c: 2 * read uninit data ?
The following reply was made to PR bin/50965; it has been noted by GNATS.
From: David Holland <dholland-bugs%netbsd.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: bin/50965: src/usr.bin/sort/msort.c: 2 * read uninit data ?
Date: Mon, 14 Mar 2016 05:54:55 +0000
On Sun, Mar 13, 2016 at 08:00:01PM +0000, Christos Zoulas wrote:
> | src/usr.bin/sort/msort.c:383]: (error) Uninitialized struct member: prec.data
> |
> | prec = malloc(offsetof(RECHEADER, data[DEFLLEN]));
> | prec_end = prec->data + DEFLLEN;
> |
>
> The checker is wrong.
To clarify: crec->data is an array, so its address is set by the
assignment of prec.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index