]> git.ipfire.org Git - thirdparty/qemu.git/commit
migration/qmp: Fix crash on setting tls-authz with null
authorPeter Xu <peterx@redhat.com>
Tue, 5 Sep 2023 16:23:32 +0000 (12:23 -0400)
committerMichael Tokarev <mjt@tls.msk.ru>
Sat, 21 Oct 2023 11:05:14 +0000 (14:05 +0300)
commit77d36ba30083265269501552e9c092e6954cd382
tree3cc271555fc1cf1d38476993b6334f09a898557b
parent85c27e5b372ad90931374f080045608275df3645
migration/qmp: Fix crash on setting tls-authz with null

QEMU will crash if anyone tries to set tls-authz (which is a type
StrOrNull) with 'null' value.  Fix it in the easy way by converting it to
qstring just like the other two tls parameters.

Cc: qemu-stable@nongnu.org # v4.0+
Fixes: d2f1d29b95 ("migration: add support for a "tls-authz" migration parameter")
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20230905162335.235619-2-peterx@redhat.com>
(cherry picked from commit 86dec715a7339fc61c3bdb9715993b277b2089db)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
(Mjt: the function is in m/migration.c, not m/option.c; minor context tweak)
migration/migration.c