Commit 77365ee135 for qemu.org
commit 77365ee135cb085b69ddf0256915ebb2de9b2e6c
Author: Fabiano Rosas <farosas@suse.de>
Date: Mon Sep 14 21:01:51 2026 -0300
migration: Rename variables in qmp_migrate_set_parameters
Give the variables in qmp_migrate_set_parameters more semantic
names.
s/params/input/
this is the user input from qapi
s/tmp/new/
this is the combination of the current parameters and the input
Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
diff --git a/migration/options.c b/migration/options.c
index f4bba8ca26..3ce15497f8 100644
--- a/migration/options.c
+++ b/migration/options.c
@@ -1599,9 +1599,9 @@ static void migrate_params_apply(MigrationParameters *params)
}
}
-void qmp_migrate_set_parameters(MigrationParameters *params, Error **errp)
+void qmp_migrate_set_parameters(MigrationParameters *input, Error **errp)
{
- MigrationParameters tmp;
+ MigrationParameters new;
/*
* Convert QTYPE_QNULL and NULL to the empty string (""). Even
@@ -1611,18 +1611,18 @@ void qmp_migrate_set_parameters(MigrationParameters *params, Error **errp)
* the options to the rest of the migration code already use
* return NULL when the empty string is found.
*/
- tls_opt_to_str(params->tls_creds);
- tls_opt_to_str(params->tls_hostname);
- tls_opt_to_str(params->tls_authz);
+ tls_opt_to_str(input->tls_creds);
+ tls_opt_to_str(input->tls_hostname);
+ tls_opt_to_str(input->tls_authz);
- migrate_params_test_apply(params, &tmp);
+ migrate_params_test_apply(input, &new);
- if (migrate_params_check(&tmp, errp)) {
- migrate_params_apply(params);
- migrate_post_update_params(params, errp);
+ if (migrate_params_check(&new, errp)) {
+ migrate_params_apply(input);
+ migrate_post_update_params(input, errp);
}
- migrate_tls_opts_free(&tmp);
- qapi_free_BitmapMigrationNodeAliasList(tmp.block_bitmap_mapping);
- qapi_free_strList(tmp.cpr_exec_command);
+ migrate_tls_opts_free(&new);
+ qapi_free_BitmapMigrationNodeAliasList(new.block_bitmap_mapping);
+ qapi_free_strList(new.cpr_exec_command);
}