mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
iscsi_direct: Don't overwrite error in virStorageBackenISCSIDirectWipeVol()
If virStorageBackendISCSIDirectVolWipeZero() fails, it has already reported an error which is probably specific enough. Do not overwrite it with some generic one. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
parent
96e5c4177e
commit
9bf194c23f
@ -679,12 +679,8 @@ virStorageBackenISCSIDirectWipeVol(virStoragePoolObjPtr pool,
|
||||
|
||||
switch ((virStorageVolWipeAlgorithm) algorithm) {
|
||||
case VIR_STORAGE_VOL_WIPE_ALG_ZERO:
|
||||
if (virStorageBackendISCSIDirectVolWipeZero(vol, iscsi) < 0) {
|
||||
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||
_("failed to wipe volume %s"),
|
||||
vol->name);
|
||||
if (virStorageBackendISCSIDirectVolWipeZero(vol, iscsi) < 0)
|
||||
goto cleanup;
|
||||
}
|
||||
break;
|
||||
case VIR_STORAGE_VOL_WIPE_ALG_TRIM:
|
||||
case VIR_STORAGE_VOL_WIPE_ALG_NNSA:
|
||||
|
Loading…
x
Reference in New Issue
Block a user