From 67b5595d3b333fc5bcf82ce1e3aedc217b68b99a Mon Sep 17 00:00:00 2001 From: Alex Bennée Date: Mon, 11 Dec 2023 14:59:59 +0000 Subject: chardev: use bool for fe_is_open MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The function qemu_chr_fe_init already treats be->fe_open as a bool and if it acts like a bool it should be one. While we are at it make the variable name more descriptive and add kdoc decorations. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20231211145959.93759-1-alex.bennee@linaro.org> --- chardev/char.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'chardev/char.c') diff --git a/chardev/char.c b/chardev/char.c index 185b5ea255..3c43fb1278 100644 --- a/chardev/char.c +++ b/chardev/char.c @@ -762,7 +762,7 @@ static int qmp_query_chardev_foreach(Object *obj, void *data) value->label = g_strdup(chr->label); value->filename = g_strdup(chr->filename); - value->frontend_open = chr->be && chr->be->fe_open; + value->frontend_open = chr->be && chr->be->fe_is_open; QAPI_LIST_PREPEND(*list, value); -- cgit 1.4.1