mirror of https://github.com/xemu-project/xemu.git
qmp: Drop superfluous special case "empty" in qmp_memchar_read()
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
13289fb5a7
commit
c287e99fe4
|
@ -2818,10 +2818,6 @@ char *qmp_memchar_read(const char *device, int64_t size,
|
||||||
}
|
}
|
||||||
|
|
||||||
count = qemu_chr_cirmem_count(chr);
|
count = qemu_chr_cirmem_count(chr);
|
||||||
if (count == 0) {
|
|
||||||
return g_strdup("");
|
|
||||||
}
|
|
||||||
|
|
||||||
size = size > count ? count : size;
|
size = size > count ? count : size;
|
||||||
read_data = g_malloc0(size + 1);
|
read_data = g_malloc0(size + 1);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue