summary refs log tree commit diff stats
path: root/scripts/tracetool/format/d.py
diff options
context:
space:
mode:
authorJuraj Marcin <jmarcin@redhat.com>2025-05-21 15:52:34 +0200
committerDaniel P. Berrangé <berrange@redhat.com>2025-05-22 11:24:41 +0100
commit316e8ee8d614f049bfae697570a5e62af450491c (patch)
treea790a66da02bbd901f61bc49512aee12dcaa80f5 /scripts/tracetool/format/d.py
parent00064705ed1f3943d3634be25da434466c87e7d5 (diff)
downloadfocaccia-qemu-316e8ee8d614f049bfae697570a5e62af450491c.tar.gz
focaccia-qemu-316e8ee8d614f049bfae697570a5e62af450491c.zip
util/qemu-sockets: Refactor inet_parse() to use QemuOpts
Currently, the inet address parser cannot handle multiple options where
one is prefixed with the name of the other. For example, with the
'keep-alive-idle' option added, the current parser cannot parse
'127.0.0.1:5000,keep-alive-idle=60,keep-alive' correctly. Instead, it
fails with "error parsing 'keep-alive' flag '-idle=60,keep-alive'".

To resolve these issues, this patch rewrites the inet address parsing
using the QemuOpts parser, which the inet_parse_flag() function tries to
mimic. This new parser supports all previously supported options and on
top of that the 'numeric' flag is now also supported. The only
difference is, the new parser produces an error if an unknown option is
passed, instead of silently ignoring it.

Signed-off-by: Juraj Marcin <jmarcin@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Diffstat (limited to 'scripts/tracetool/format/d.py')
0 files changed, 0 insertions, 0 deletions