diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-07-29 17:47:00 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-07-29 17:47:00 +0200 |
commit | 35cdc5b562dc2c8c843637cd88cf5404c5efc538 (patch) | |
tree | 6c72d6f29605dadb0a9e83bc710cebc83e6ab577 /src/config.y | |
parent | eb918a116dfb837999050e0940ea3cd069f7c765 (diff) | |
download | fastd-35cdc5b562dc2c8c843637cd88cf5404c5efc538.tar fastd-35cdc5b562dc2c8c843637cd88cf5404c5efc538.zip |
char* constness cleanup in config parser
Diffstat (limited to 'src/config.y')
-rw-r--r-- | src/config.y | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/config.y b/src/config.y index 75f2019..65e95b3 100644 --- a/src/config.y +++ b/src/config.y @@ -41,12 +41,13 @@ %union { int num; fastd_string_stack_t *str; - char *error; bool boolean; fastd_tristate_t tristate; struct in_addr addr4; struct in6_addr addr6; fastd_peer_address_t addr; + + const char *error; } %token START_CONFIG @@ -123,7 +124,7 @@ #include <stdint.h> #include <unistd.h> - void fastd_config_error(YYLTYPE *loc, fastd_context_t *ctx, fastd_config_t *conf, const char *filename, int depth, char *s); + void fastd_config_error(YYLTYPE *loc, fastd_context_t *ctx, fastd_config_t *conf, const char *filename, int depth, const char *s); } @@ -535,6 +536,6 @@ port: colon_or_port TOK_INTEGER { ; %% -void fastd_config_error(YYLTYPE *loc, fastd_context_t *ctx, fastd_config_t *conf, const char *filename, int depth, char *s) { +void fastd_config_error(YYLTYPE *loc, fastd_context_t *ctx, fastd_config_t *conf, const char *filename, int depth, const char *s) { pr_error(ctx, "config error: %s at %s:%i:%i", s, filename, loc->first_line, loc->first_column); } |