]> git.ipfire.org Git - thirdparty/libvirt.git/commit
conf: reject duplicate paths in device weights
authorEric Blake <eblake@redhat.com>
Tue, 29 Nov 2011 20:23:17 +0000 (13:23 -0700)
committerEric Blake <eblake@redhat.com>
Wed, 30 Nov 2011 19:15:22 +0000 (12:15 -0700)
commit9b524ff0404de655654cd610f8886ea220b59b96
tree5b8af499c0309fa1c4b55cab127af92637dc6206
parent7e976db4ea7f0a2e141057a7ca8fe805523ed836
conf: reject duplicate paths in device weights

The next patch will make it possible to have virDomainSetBlkioParameters
leave device weights unchanged if they are not mentioned in the incoming
string, but this only works if the list of block weights does not allow
duplicate paths.  Technically, a user can still confuse libvirt by
passing alternate spellings that resolve to the same device, but it
is not worth worrying about working around that kind of abuse.

* src/conf/domain_conf.c (virDomainDefParseXML): Require unique
paths.
src/conf/domain_conf.c