resolve: shorten conf parser name and realign gperf table

This commit is contained in:
Yu Watanabe
2025-09-17 22:07:27 +09:00
parent 6fdaa3d22c
commit a5527e2228
3 changed files with 14 additions and 14 deletions
+8 -8
View File
@@ -18,11 +18,11 @@ struct ConfigPerfItem;
%struct-type
%includes
%%
Service.Name, config_parse_dnssd_registered_service_name, 0, 0
Service.Type, config_parse_dnssd_registered_service_type, 0, 0
Service.SubType, config_parse_dnssd_registered_service_subtype, 0, 0
Service.Port, config_parse_ip_port, 0, offsetof(DnssdRegisteredService, port)
Service.Priority, config_parse_uint16, 0, offsetof(DnssdRegisteredService, priority)
Service.Weight, config_parse_uint16, 0, offsetof(DnssdRegisteredService, weight)
Service.TxtText, config_parse_dnssd_txt, DNS_TXT_ITEM_TEXT, 0
Service.TxtData, config_parse_dnssd_txt, DNS_TXT_ITEM_DATA, 0
Service.Name, config_parse_dnssd_name, 0, 0
Service.Type, config_parse_dnssd_type, 0, 0
Service.SubType, config_parse_dnssd_subtype, 0, 0
Service.Port, config_parse_ip_port, 0, offsetof(DnssdRegisteredService, port)
Service.Priority, config_parse_uint16, 0, offsetof(DnssdRegisteredService, priority)
Service.Weight, config_parse_uint16, 0, offsetof(DnssdRegisteredService, weight)
Service.TxtText, config_parse_dnssd_txt, DNS_TXT_ITEM_TEXT, 0
Service.TxtData, config_parse_dnssd_txt, DNS_TXT_ITEM_DATA, 0
+3 -3
View File
@@ -413,7 +413,7 @@ int dnssd_signal_conflict(Manager *manager, const char *name) {
return 0;
}
int config_parse_dnssd_registered_service_name(
int config_parse_dnssd_name(
const char *unit,
const char *filename,
unsigned line,
@@ -467,7 +467,7 @@ int config_parse_dnssd_registered_service_name(
return free_and_strdup_warn(&s->name_template, rvalue);
}
int config_parse_dnssd_registered_service_type(
int config_parse_dnssd_type(
const char *unit,
const char *filename,
unsigned line,
@@ -503,7 +503,7 @@ int config_parse_dnssd_registered_service_type(
return 0;
}
int config_parse_dnssd_registered_service_subtype(
int config_parse_dnssd_subtype(
const char *unit,
const char *filename,
unsigned line,
+3 -3
View File
@@ -63,7 +63,7 @@ int dnssd_signal_conflict(Manager *manager, const char *name);
const struct ConfigPerfItem* resolved_dnssd_gperf_lookup(const char *key, GPERF_LEN_TYPE length);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_registered_service_name);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_registered_service_subtype);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_registered_service_type);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_name);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_subtype);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_type);
CONFIG_PARSER_PROTOTYPE(config_parse_dnssd_txt);