mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-03 17:47:15 +03:00
* src/virsh.c: add error messages for negative memory size as
pointed out by Masayuki Sunou Daniel
This commit is contained in:
parent
633a3bef0d
commit
4ffe066dd8
@ -1,3 +1,8 @@
|
||||
Tue Mar 20 16:40:06 CET 2007 Daniel Veillard <veillard@redhat.com>
|
||||
|
||||
* src/virsh.c: add error messages for negative memory size as
|
||||
pointed out by Masayuki Sunou
|
||||
|
||||
Tue Mar 20 16:30:29 CET 2007 Daniel Veillard <veillard@redhat.com>
|
||||
|
||||
* src/xen_internal.c: applied patch from Atsushi SAKAI fixing
|
||||
|
@ -1461,6 +1461,7 @@ cmdSetmem(vshControl * ctl, vshCmd * cmd)
|
||||
bytes = vshCommandOptInt(cmd, "bytes", &bytes);
|
||||
if (bytes <= 0) {
|
||||
virDomainFree(dom);
|
||||
vshError(ctl, FALSE, _("Invalid value of %d for memory size"), bytes);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@ -1504,6 +1505,7 @@ cmdSetmaxmem(vshControl * ctl, vshCmd * cmd)
|
||||
bytes = vshCommandOptInt(cmd, "bytes", &bytes);
|
||||
if (bytes <= 0) {
|
||||
virDomainFree(dom);
|
||||
vshError(ctl, FALSE, _("Invalid value of %d for memory size"), bytes);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user