提交 6629fa64 编写于 作者: J Jan Kiszka 提交者: Aurelien Jarno

Fix corner case in chardev udp: parameter

The missing '@' broke 'udp::<port>@:<port>' parsing.
Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: NAurelien Jarno <aurelien@aurel32.net>
(cherry picked from commit 39324ca4)
上级 2a7996ce
......@@ -2317,7 +2317,7 @@ QemuOpts *qemu_chr_parse_compat(const char *label, const char *filename)
qemu_opt_set(opts, "backend", "udp");
if (sscanf(p, "%64[^:]:%32[^@,]%n", host, port, &pos) < 2) {
host[0] = 0;
if (sscanf(p, ":%32[^,]%n", port, &pos) < 1) {
if (sscanf(p, ":%32[^@,]%n", port, &pos) < 1) {
goto fail;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册