]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: Validate QoS values in qemuDomainSetInterfaceParameters()
authorMichal Privoznik <mprivozn@redhat.com>
Wed, 27 Nov 2024 11:25:12 +0000 (12:25 +0100)
committerMichal Privoznik <mprivozn@redhat.com>
Wed, 27 Nov 2024 14:11:13 +0000 (15:11 +0100)
commitc4d6bd3bf5fe967c5523e32d980dd17184d66715
tree5c180106c97d017424148fcab5f333d22080dc78
parent9b55a130b7232d24d46e7bc5a5730f80f30bc3bc
qemu: Validate QoS values in qemuDomainSetInterfaceParameters()

This is similar to one of my previous commits (v10.7.0-rc1~22)
which introduced a check that <bandwidth/> values fit into
certain limits. My original commit validated values when parsing
<bandwidth/> XML, but completely missed the case when values are
set over virDomainSetInterfaceParameters() API.

Solution is simple - just perform validation after bandwidth
structure is reconstructed from arguments passed to the API.

Resolves: https://issues.redhat.com/browse/RHEL-65372
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
src/qemu/qemu_driver.c