Subject: Re: sys/dev/scsipi/scsipi_base.c
To: None <current-users@netbsd.org>
From: David Huang <khym@azeotrope.org>
List: current-users
Date: 01/06/2008 04:48:28
On Jan 6, 2008, at 4:41 AM, John R. Shannon wrote:
> Line 1124 has:
>
> memcpy(inqbuf->vendor, "ADAPTEC ACB-4000 ", 28);
>
> and line 1144 has:
>
> memcpy(inqbuf->vendor, "EMULEX MT-02 QIC ", 28);
>
> yet inqbuf->vendor is declared in struct scsipi_inquiry_data as:
>
> char vendor[8];
It's immediately followed by
char product[16];
char revision[4];
for a total of 28 bytes. Looks like the intention is to set all three
with one memcpy().
--
Name: Dave Huang | Mammal, mammal / their names are called /
INet: khym@azeotrope.org | they raise a paw / the bat, the cat /
FurryMUCK: Dahan | dolphin and dog / koala bear and hog -- TMBG
Dahan: Hani G Y+C 31 Y++ L+++ W- C++ T++ A+ E+ S++ V++ F- Q+++ P+ B+ PA
+ PL++