[libvirt] [PATCH] scsi: Force error for SCSI pools on virStorageBackendSCSIFindLUs failure

Related to : https://bugzilla.redhat.com/show_bug.cgi?id=1171933 Rather than ignore the return status from virStorageBackendSCSIFindLUs, cause a failure to start the pool if a -1 is returned. Issue was noted during testing of the bz for iscsi that 'scsi' and 'fc' pools don't fail. Signed-off-by: John Ferlan <jferlan@redhat.com> --- src/storage/storage_backend_scsi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/storage/storage_backend_scsi.c b/src/storage/storage_backend_scsi.c index b426145..a593a2b 100644 --- a/src/storage/storage_backend_scsi.c +++ b/src/storage/storage_backend_scsi.c @@ -935,7 +935,8 @@ virStorageBackendSCSIRefreshPool(virConnectPtr conn ATTRIBUTE_UNUSED, if (virStorageBackendSCSITriggerRescan(host) < 0) goto out; - ignore_value(virStorageBackendSCSIFindLUs(pool, host)); + if (virStorageBackendSCSIFindLUs(pool, host) < 0) + goto out; ret = 0; out: -- 2.1.0

On Tue, Jun 23, 2015 at 02:50:14PM -0400, John Ferlan wrote:
Related to :
https://bugzilla.redhat.com/show_bug.cgi?id=1171933
Rather than ignore the return status from virStorageBackendSCSIFindLUs, cause a failure to start the pool if a -1 is returned. Issue was noted during testing of the bz for iscsi that 'scsi' and 'fc' pools don't fail.
Signed-off-by: John Ferlan <jferlan@redhat.com> --- src/storage/storage_backend_scsi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
ACK Jan
participants (2)
-
John Ferlan
-
Ján Tomko