[stgt] [PATCH] bs_sheepdog.c: fix error handling issue in bs_sheepdog_request()
Ryusuke Konishi
konishi.ryusuke at lab.ntt.co.jp
Thu Oct 31 14:36:04 CET 2013
bs_sheepdog_request function, the request handler of sheepdog driver,
doesn't set scsi status code if the driver failed to create writable
VDI from snapshot.
In that case, CHECK_CONDITION result code should be set to cmd->result
through scsi_set_result() macro. This fix corrects the error
handling issue.
Signed-off-by: Ryusuke Konishi <konishi.ryusuke at lab.ntt.co.jp>
---
usr/bs_sheepdog.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/usr/bs_sheepdog.c b/usr/bs_sheepdog.c
index 7341708..1dda915 100644
--- a/usr/bs_sheepdog.c
+++ b/usr/bs_sheepdog.c
@@ -1184,7 +1184,7 @@ static void bs_sheepdog_request(struct scsi_cmd *cmd)
" snapshot failed\n");
set_medium_error(&result, &key, &asc);
- return;
+ break;
}
ai->is_snapshot = 0;
}
--
1.7.9.3
--
To unsubscribe from this list: send the line "unsubscribe stgt" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
More information about the stgt
mailing list