mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
screenshot: Set access rights to temporary file
Although we create a temporary file, it is owned by root:root and have rights 0600. In case qemu does not run under root, it is unable to write to that file and thus we transfer 0B sized file.
This commit is contained in:
@@ -2729,6 +2729,8 @@ qemuDomainScreenshot(virDomainPtr dom,
|
||||
goto endjob;
|
||||
}
|
||||
|
||||
virSecurityManagerSetSavedStateLabel(qemu_driver->securityManager, vm, tmp);
|
||||
|
||||
qemuDomainObjEnterMonitor(vm);
|
||||
if (qemuMonitorScreendump(priv->mon, tmp) < 0) {
|
||||
qemuDomainObjExitMonitor(vm);
|
||||
|
||||
Reference in New Issue
Block a user