]> xenbits.xensource.com Git - qemu-xen.git/commit
xen: do not use '%ms' scanf specifier master stable-4.20 staging staging-4.20
authorRoger Pau Monne <roger.pau@citrix.com>
Fri, 10 Jan 2025 09:35:31 +0000 (10:35 +0100)
committerAnthony PERARD <anthony.perard@citrix.com>
Thu, 24 Apr 2025 08:51:17 +0000 (10:51 +0200)
commite064f42c80be6f6ff8c12dcb2a663bdf70f965f6
treed61f6fe938672c00778d69403cf3ea5b0d101237
parent82354c9f2431a1c35bc12297697b8ab48f206f27
xen: do not use '%ms' scanf specifier

The 'm' parameter used to request auto-allocation of the destination variable
is not supported on FreeBSD, and as such leads to failures to parse.

What's more, the current usage of '%ms' with xs_node_scanf() is pointless, as
it just leads to a double allocation of the same string.  Instead use
xs_node_read() to read the whole xenstore node.

Fixes: a783f8ad4ec9 ('xen: add a mechanism to automatically create XenDevice-s...')
Fixes: 9b7737469080 ('hw/xen: update Xen console to XenDevice model')
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
hw/block/xen-block.c
hw/char/xen_console.c
hw/xen/xen-bus.c
include/hw/xen/xen-bus.h