mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 12:35:17 +00:00
conf: virDomainMemoryDefValidate: Improve error message
An explicit limit would be more user friendly. Add the limit to error message. Before this commit: ``` error: requested size must be smaller than or equal to @size ``` Now: ``` error: requested size must be smaller than or equal to @size (8388608KiB) ``` Signed-off-by: Liu Yiding <liuyd.fnst@fujitsu.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
088e92e0cc
commit
0dd1fdae2e
@ -2194,8 +2194,9 @@ virDomainMemoryDefValidate(const virDomainMemoryDef *mem,
|
||||
|
||||
case VIR_DOMAIN_MEMORY_MODEL_VIRTIO_MEM:
|
||||
if (mem->requestedsize > mem->size) {
|
||||
virReportError(VIR_ERR_XML_DETAIL, "%s",
|
||||
_("requested size must be smaller than or equal to @size"));
|
||||
virReportError(VIR_ERR_XML_DETAIL,
|
||||
_("requested size must be smaller than or equal to @size (%lluKiB)"),
|
||||
mem->size);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user