Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 287364
b: refs/heads/master
c: 95fe1ee
h: refs/heads/master
v: v3
  • Loading branch information
Sebastian Andrzej Siewior authored and Nicholas Bellinger committed Feb 7, 2012
1 parent 67266f3 commit c2dbc20
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bf0053550aebe56f3bb5dd793e9de69238b5b945
refs/heads/master: 95fe1ee41e23fa271416da67483594dde74bc6ca
14 changes: 4 additions & 10 deletions trunk/drivers/target/target_core_cdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1058,11 +1058,8 @@ int target_emulate_request_sense(struct se_task *task)
*/
buf[0] = 0x70;
buf[SPC_SENSE_KEY_OFFSET] = UNIT_ATTENTION;
/*
* Make sure request data length is enough for additional
* sense data.
*/
if (cmd->data_length <= 18) {

if (cmd->data_length < 18) {
buf[7] = 0x00;
err = -EINVAL;
goto end;
Expand All @@ -1079,11 +1076,8 @@ int target_emulate_request_sense(struct se_task *task)
*/
buf[0] = 0x70;
buf[SPC_SENSE_KEY_OFFSET] = NO_SENSE;
/*
* Make sure request data length is enough for additional
* sense data.
*/
if (cmd->data_length <= 18) {

if (cmd->data_length < 18) {
buf[7] = 0x00;
err = -EINVAL;
goto end;
Expand Down

0 comments on commit c2dbc20

Please sign in to comment.