summaryrefslogtreecommitdiffstats
path: root/src/providers/data_provider/dp_target_hostid.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/providers/data_provider/dp_target_hostid.c')
-rw-r--r--src/providers/data_provider/dp_target_hostid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/providers/data_provider/dp_target_hostid.c b/src/providers/data_provider/dp_target_hostid.c
index a47601f0b..93f9fdac5 100644
--- a/src/providers/data_provider/dp_target_hostid.c
+++ b/src/providers/data_provider/dp_target_hostid.c
@@ -46,7 +46,7 @@ errno_t dp_host_handler(struct sbus_request *sbus_req,
}
data->name = name;
- data->alias = alias[0] == '\0' ? NULL : alias;
+ data->alias = SBUS_SET_STRING(alias);
key = talloc_asprintf(data, "%s:%s", name,
(data->alias == NULL ? "(null)" : data->alias));