diff --git a/src/kernel/config.c b/src/kernel/config.c index 02ed9894d..1076e9432 100644 --- a/src/kernel/config.c +++ b/src/kernel/config.c @@ -782,11 +782,18 @@ void config_set_from(const dictionary *d, const char *valid_keys[]) } } -void config_set(const char *key, const char *value) { +void config_set(const char *key, const char *value) +{ ++config_cache_key; set_param(&configuration, key, value); } +void config_set_int(const char *key, int value) +{ + ++config_cache_key; + set_param(&configuration, key, itoa10(value)); +} + const char *config_get(const char *key) { return get_param(configuration, key); } diff --git a/src/kernel/config.h b/src/kernel/config.h index f80214fde..4cf0650ff 100644 --- a/src/kernel/config.h +++ b/src/kernel/config.h @@ -121,6 +121,7 @@ extern "C" { void free_params(struct param **pp); void config_set(const char *key, const char *value); + void config_set_int(const char *key, int value); void config_set_from(const struct _dictionary_ *d, const char *keys[]); const char *config_get(const char *key); int config_get_int(const char *key, int def);