[Libvir] [PATCH] setmem checks
Richard W.M. Jones
rjones at redhat.com
Fri Jun 15 07:59:50 UTC 2007
Mark Johnson wrote:
> 1673a1675,1677
>> if (virDomainGetInfo(dom, &info) != 0) {
>> info.maxMem = 0;
>> }
> 1675c1679
> < if (kilobytes <= 0) {
> ---
>> if ((kilobytes <= 0) || (kilobytes > info.maxMem)) {
I don't understand this bit. If virDomainGetInfo fails then it'll
always give an error because kilobytes > info.maxMem (== 0) ?
Rich.
--
Emerging Technologies, Red Hat - http://et.redhat.com/~rjones/
Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod
Street, Windsor, Berkshire, SL4 1TE, United Kingdom. Registered in
England and Wales under Company Registration No. 03798903
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3237 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20070615/e98ef3a7/attachment-0001.bin>
More information about the libvir-list
mailing list