diff options
author | Lennart Poettering <lennart@poettering.net> | 2018-05-22 13:10:17 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2018-05-22 13:18:44 +0200 |
commit | a2106925257945fa2cfc8735fcb49ebcaff609d6 (patch) | |
tree | d3b3968918f8bbf4767c5d77f6ecedacaad9f367 /src/shared/resolve-util.h | |
parent | 1f12b48a730bfbca991d0ae51e3a740d59faf201 (diff) | |
download | systemd-a2106925257945fa2cfc8735fcb49ebcaff609d6.tar.gz |
tree-wide: port over all code to the new CONFIG_PARSER_PROTOTYPE() macro
This makes most header files easier to look at. Also Emacs gets really
slow when browsing through large sections of overly long prototypes,
which is much improved by this macro.
We should probably not do something similar with too many other cases,
as macros like this might help readability for some, but make it worse
for others. But I think given the complexity of this specific prototype
and how often we use it, it's worth doing.
Diffstat (limited to 'src/shared/resolve-util.h')
-rw-r--r-- | src/shared/resolve-util.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/shared/resolve-util.h b/src/shared/resolve-util.h index 260e534d63..069e32963e 100644 --- a/src/shared/resolve-util.h +++ b/src/shared/resolve-util.h @@ -7,6 +7,7 @@ Copyright 2016 Lennart Poettering ***/ +#include "conf-parser.h" #include "macro.h" typedef enum ResolveSupport ResolveSupport; @@ -38,8 +39,8 @@ enum DnssecMode { _DNSSEC_MODE_INVALID = -1 }; -int config_parse_resolve_support(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata); -int config_parse_dnssec_mode(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata); +CONFIG_PARSER_PROTOTYPE(config_parse_resolve_support); +CONFIG_PARSER_PROTOTYPE(config_parse_dnssec_mode); const char* resolve_support_to_string(ResolveSupport p) _const_; ResolveSupport resolve_support_from_string(const char *s) _pure_; |