diff options
author | Eric Leblond <eric@regit.org> | 2013-01-18 19:41:19 +0100 |
---|---|---|
committer | Eric Leblond <eric@regit.org> | 2013-01-18 19:41:19 +0100 |
commit | a385170fee2e406afe0387f99361eebe7ce2b3c8 (patch) | |
tree | e409aa170132953983063afd29613137da25570e /src | |
parent | ec1da580639aa1779bbeb66bb9bcd266c76b5925 (diff) |
conf: add flag to allow option setup tuning
This patch adds a flag to the config_entry structure to be able to
tune setup. First usage is to ask config parser not to update a key
if it has been already set.
Diffstat (limited to 'src')
-rw-r--r-- | src/conffile.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/conffile.c b/src/conffile.c index b27187e..8dbd726 100644 --- a/src/conffile.c +++ b/src/conffile.c @@ -167,7 +167,8 @@ int config_parse_file(const char *section, struct config_keyset *kset) for (i = 0; i < kset->num_ces; i++) { struct config_entry *ce = &kset->ces[i]; pr_debug("parse main loop, key: %s\n", ce->key); - if (strcmp(ce->key, (char *) &wordbuf)) { + if ((strcmp(ce->key, (char *) &wordbuf)) || + ce->flag & CONFIG_FLAG_VAL_PROTECTED) { continue; } |