mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
conf: Remove incorrect check when encoding shmem audit message
Remove the !size check since size is initialized to NULL and thus causing the condition to always be true
This commit is contained in:
parent
4ac20b3ae4
commit
c951cdbff9
@ -983,7 +983,7 @@ virDomainAuditShmem(virDomainObjPtr vm,
|
||||
|
||||
virUUIDFormat(vm->def->uuid, uuidstr);
|
||||
|
||||
if (!vmname || !src || !size || !shmem ||
|
||||
if (!vmname || !src || !shmem ||
|
||||
virAsprintfQuiet(&size, "%llu", def->size) < 0) {
|
||||
VIR_WARN("OOM while encoding audit message");
|
||||
goto cleanup;
|
||||
@ -997,7 +997,7 @@ virDomainAuditShmem(virDomainObjPtr vm,
|
||||
|
||||
VIR_AUDIT(VIR_AUDIT_RECORD_RESOURCE, success,
|
||||
"virt=%s resrc=shmem reason=%s %s uuid=%s size=%s %s %s",
|
||||
virt, reason, vmname, uuidstr, size ?: "?", shmem, src);
|
||||
virt, reason, vmname, uuidstr, size, shmem, src);
|
||||
|
||||
cleanup:
|
||||
VIR_FREE(vmname);
|
||||
|
Loading…
Reference in New Issue
Block a user