From 0261c2ab42185d8fd8050a8903a9a26ff638ea10 Mon Sep 17 00:00:00 2001 From: Zhenguo Yao Date: Thu, 16 Feb 2023 10:48:37 +0800 Subject: [PATCH] qemu: fix reconnect of unix socket is wrong 'reconnect' parameter doesn't pass to qemu properly when hotplug vhost-user device to vm. Fix this by making 'reconnect' to get correct value. Signed-off-by: Zhenguo Yao Reviewed-by: Jonathon Jongsma --- src/qemu/qemu_monitor_json.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index d05ca2932f..ba6276ec8e 100644 --- a/src/qemu/qemu_monitor_json.c +++ b/src/qemu/qemu_monitor_json.c @@ -6450,7 +6450,7 @@ qemuMonitorJSONAttachCharDevGetProps(const char *chrID, return NULL; if (chr->data.nix.reconnect.enabled == VIR_TRISTATE_BOOL_YES) - reconnect = chr->data.tcp.reconnect.timeout; + reconnect = chr->data.nix.reconnect.timeout; else if (chr->data.nix.reconnect.enabled == VIR_TRISTATE_BOOL_NO) reconnect = 0; }