RE: [Scsirastools-developers] [PATCH] support more devices in sgdiag and check devlist array bo unds
Brought to you by:
arcress
From: Cress, A. R <and...@in...> - 2005-05-11 15:32:44
|
Nate, The size does need to be greater than 32. Thanks for the patch. However, as it is it adds 140 bytes * 32K devices =3D about 4.48MB to = each utility. This is pretty big, but is doable for all but sgraidmon, since most of the utilities will run only occasionally and won't stay around in memory. Hmmm. Do we really need 32K scsi devices for an enclosure? Is there a real use case for more than say 512 or 1024? =20 Andy -----Original Message----- From: scs...@li... [mailto:scs...@li...] On Behalf Of Dailey, Nate Sent: Tuesday, May 10, 2005 3:40 PM To: 'scs...@li...' Cc: Dailey, Nate Subject: [Scsirastools-developers] [PATCH] support more devices in sgdiag and check devlist array bo unds I hit a segmentation fault in sgdiag on a system with more than 32 devices. It turns out that there's no bounds checking on the devlist array, so additional devices trample on memory outside the devlist. The attached patch prevents writing outside the bounds of the array, and also ups the number of devices. It looks like the same problem exists in sgdefects, sgdskfl, and sgmode, but I haven't tested them to verify. This patch is against scsirastools 1.4.14. Nate Dailey Stratus Technologies |