mirror of https://gitee.com/openkylin/libvirt.git
Allow virDomain(SG)etGuestVcpus on read-write connection only
Guest agent interaction is considered privileged. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1349272
This commit is contained in:
parent
21b56a6055
commit
dfeb19ff60
|
@ -11873,6 +11873,8 @@ virDomainGetGuestVcpus(virDomainPtr domain,
|
|||
virResetLastError();
|
||||
|
||||
virCheckDomainReturn(domain, -1);
|
||||
virCheckReadOnlyGoto(domain->conn->flags, error);
|
||||
|
||||
virCheckNonNullArgGoto(params, error);
|
||||
virCheckNonNullArgGoto(nparams, error);
|
||||
|
||||
|
@ -11929,6 +11931,8 @@ virDomainSetGuestVcpus(virDomainPtr domain,
|
|||
virResetLastError();
|
||||
|
||||
virCheckDomainReturn(domain, -1);
|
||||
virCheckReadOnlyGoto(domain->conn->flags, error);
|
||||
|
||||
virCheckNonNullArgGoto(cpumap, error);
|
||||
|
||||
if (domain->conn->driver->domainSetGuestVcpus) {
|
||||
|
|
Loading…
Reference in New Issue