mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
qemu: Fix virFileMakePath error handling in snapshot creation
virFileMakePath returns an errno value on error, that will never be negative. An virFileMakePath error would have been ignored here, instead of being reported correctly.
This commit is contained in:
parent
4a6d4d4285
commit
4a03db81cd
@ -7498,7 +7498,7 @@ static int qemuDomainSnapshotWriteMetadata(virDomainObjPtr vm,
|
||||
goto cleanup;
|
||||
}
|
||||
err = virFileMakePath(snapDir);
|
||||
if (err < 0) {
|
||||
if (err != 0) {
|
||||
virReportSystemError(err, _("cannot create snapshot directory '%s'"),
|
||||
snapDir);
|
||||
goto cleanup;
|
||||
|
Loading…
x
Reference in New Issue
Block a user