]> git.ipfire.org Git - thirdparty/libvirt.git/commit
storage: Use consistent error preservation and restoration calls
authorJohn Ferlan <jferlan@redhat.com>
Thu, 6 Dec 2018 17:33:30 +0000 (12:33 -0500)
committerJohn Ferlan <jferlan@redhat.com>
Wed, 16 Oct 2019 19:24:41 +0000 (15:24 -0400)
commit7c47becf765541bbafecdafff12a4b81967806db
treeae47d0fc4fd0fad12ee8c3a8f8970ef9206ab706
parent28805f3d86dcfdc5227e04834d2b544d153e7d88
storage: Use consistent error preservation and restoration calls

Provide some consistency over error message variable name and usage
when saving error messages across possible other errors or possibility
of resetting of the last error.

Instead of virSaveLastError paired up with virSetError and virFreeError,
we should use the newer virErrorPreserveLast and virRestoreError.

Signed-off-by: John Ferlan <jferlan@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/storage/storage_backend_disk.c
src/storage/storage_backend_logical.c
src/storage/storage_driver.c