The converted string is used exactly once so we can call the conversion without storing the result in a variable.
Signed-off-by: Peter Krempa <pkre...@redhat.com> --- src/conf/snapshot_conf.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/conf/snapshot_conf.c b/src/conf/snapshot_conf.c index aeebe2fb33..10eb584a1c 100644 --- a/src/conf/snapshot_conf.c +++ b/src/conf/snapshot_conf.c @@ -709,12 +709,10 @@ virDomainSnapshotAlignDisks(virDomainSnapshotDefPtr snapdef, snapdisk->snapshot != default_snapshot && !(snapdisk->snapshot == VIR_DOMAIN_SNAPSHOT_LOCATION_NONE && disk_snapshot == VIR_DOMAIN_SNAPSHOT_LOCATION_NONE)) { - const char *tmp; - - tmp = virDomainSnapshotLocationTypeToString(default_snapshot); virReportError(VIR_ERR_CONFIG_UNSUPPORTED, _("disk '%s' must use snapshot mode '%s'"), - snapdisk->name, tmp); + snapdisk->name, + virDomainSnapshotLocationTypeToString(default_snapshot)); return -1; } if (snapdisk->src->path && -- 2.26.2