diff options
author | Juan Quintela <quintela@redhat.com> | 2023-03-02 12:37:21 +0100 |
---|---|---|
committer | Juan Quintela <quintela@redhat.com> | 2023-04-27 16:37:28 +0200 |
commit | 1f2f366c328e851f302c3a97ce4ac18f86a64279 (patch) | |
tree | f8a9359d8bd5f9b624862ff1265fd2eafae23cd9 /migration/tls.c | |
parent | 2eb0308bbd5e20bb20229c790dc2c7f1ae8e3ba9 (diff) |
migration: Create migrate_tls_hostname() function
Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
---
Moved the type to const char * (vladimir)
Diffstat (limited to 'migration/tls.c')
-rw-r--r-- | migration/tls.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/migration/tls.c b/migration/tls.c index 184db4d7bf..cd29177957 100644 --- a/migration/tls.c +++ b/migration/tls.c @@ -130,8 +130,9 @@ QIOChannelTLS *migration_tls_client_create(MigrationState *s, return NULL; } - if (s->parameters.tls_hostname && *s->parameters.tls_hostname) { - hostname = s->parameters.tls_hostname; + const char *tls_hostname = migrate_tls_hostname(); + if (tls_hostname && *tls_hostname) { + hostname = tls_hostname; } return qio_channel_tls_new_client(ioc, creds, hostname, errp); |