tree-wide: use typed SD_JSON_BUILD_PAIR_* macros more

This commit is contained in:
Frantisek Sumsal
2026-03-05 10:27:58 +01:00
parent 41d9419562
commit a8335fb91f
11 changed files with 99 additions and 99 deletions
+2 -2
View File
@@ -476,9 +476,9 @@ static int list_machine_one_and_maybe_read_metadata(sd_varlink *link, Machine *m
r = sd_json_buildo(
&v,
SD_JSON_BUILD_PAIR("name", SD_JSON_BUILD_STRING(m->name)),
SD_JSON_BUILD_PAIR_STRING("name", m->name),
SD_JSON_BUILD_PAIR_CONDITION(!sd_id128_is_null(m->id), "id", SD_JSON_BUILD_ID128(m->id)),
SD_JSON_BUILD_PAIR("class", SD_JSON_BUILD_STRING(machine_class_to_string(m->class))),
SD_JSON_BUILD_PAIR_STRING("class", machine_class_to_string(m->class)),
JSON_BUILD_PAIR_STRING_NON_EMPTY("service", m->service),
JSON_BUILD_PAIR_STRING_NON_EMPTY("rootDirectory", m->root_directory),
JSON_BUILD_PAIR_STRING_NON_EMPTY("unit", m->unit),