Part of patch from #6840: GCC 4.5 complains about an out of bound access on version_descriptor, use the next field instead

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42249 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2011-06-19 18:05:22 +00:00
parent 83424735a8
commit 1f5188bb43

View File

@ -117,7 +117,7 @@ scsi_scan_get_inquiry(scsi_ccb *worker_req, scsi_res_inquiry *new_inquiry_data)
// bad luck // bad luck
if (std::min((int)cmd->allocation_length, if (std::min((int)cmd->allocation_length,
new_inquiry_data->additional_length + 4) new_inquiry_data->additional_length + 4)
>= (int)offsetof(scsi_res_inquiry, version_descriptor[9])) { >= (int)offsetof(scsi_res_inquiry, _res74)) {
int i, previousStandard = -1; int i, previousStandard = -1;
for (i = 0; i < 8; ++i) { for (i = 0; i < 8; ++i) {