Philippe Mathieu-Daudé <f4...@amsat.org> writes: > On Thu, Sep 15, 2022 at 10:52 PM Markus Armbruster <arm...@redhat.com> wrote: >> >> The has_FOO for pointer-valued FOO are redundant, except for arrays. >> They are also a nuisance to work with. Recent commit "qapi: Start to >> elide redundant has_FOO in generated C" provided the means to elide >> them step by step. This is the step for qapi/migration.json. >> >> Said commit explains the transformation in more detail. The invariant >> violations mentioned there do not occur here. >> >> Cc: Juan Quintela <quint...@redhat.com> >> Cc: Dr. David Alan Gilbert <dgilb...@redhat.com> >> Signed-off-by: Markus Armbruster <arm...@redhat.com> >> --- >> migration/block-dirty-bitmap.c | 4 ++-- >> migration/colo.c | 1 - >> migration/migration.c | 27 ++++++++------------------- >> monitor/hmp-cmds.c | 26 +++++++++++--------------- >> monitor/misc.c | 2 +- >> scripts/qapi/schema.py | 1 - >> 6 files changed, 22 insertions(+), 39 deletions(-) > >> @@ -1556,7 +1548,7 @@ static bool migrate_params_check(MigrationParameters >> *params, Error **errp) >> #ifdef CONFIG_LINUX >> if (migrate_use_zero_copy_send() && >> ((params->has_multifd_compression && params->multifd_compression) || >> - (params->has_tls_creds && params->tls_creds && >> *params->tls_creds))) { >> + (params->tls_creds && params->tls_creds && *params->tls_creds))) { >> error_setg(errp, >> "Zero copy only available for non-compressed non-TLS >> multifd migration"); >> return false; > > Checking params->tls_creds once should be enough ;)
Can't deny that! Will tidy up, thanks!