Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107574645
D29991.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
896 B
Referenced Files
None
Subscribers
None
D29991.diff
View Options
diff --git a/sys/cam/scsi/scsi_xpt.c b/sys/cam/scsi/scsi_xpt.c
--- a/sys/cam/scsi/scsi_xpt.c
+++ b/sys/cam/scsi/scsi_xpt.c
@@ -1210,8 +1210,6 @@
if (periph_qual == SID_QUAL_LU_CONNECTED ||
periph_qual == SID_QUAL_LU_OFFLINE) {
- u_int8_t len;
-
/*
* We conservatively request only
* SHORT_INQUIRY_LEN bytes of inquiry
@@ -1222,11 +1220,9 @@
* the amount of information the device
* is willing to give.
*/
- len = inq_buf->additional_length
- + offsetof(struct scsi_inquiry_data,
- additional_length) + 1;
if (softc->action == PROBE_INQUIRY
- && len > SHORT_INQUIRY_LENGTH) {
+ && SID_ADDITIONAL_LENGTH(inq_buf)
+ > SHORT_INQUIRY_LENGTH) {
PROBE_SET_ACTION(softc, PROBE_FULL_INQUIRY);
xpt_release_ccb(done_ccb);
xpt_schedule(periph, priority);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Jan 17, 2:51 AM (21 h, 9 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15832338
Default Alt Text
D29991.diff (896 B)
Attached To
Mode
D29991: cam: fix integer overflow during inquiry
Attached
Detach File
Event Timeline
Log In to Comment