diff options
author | NeilBrown <neilb@suse.de> | 2013-09-03 10:05:59 +1000 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2013-09-03 10:05:59 +1000 |
commit | 3c6e95c1aa73b54865c96b1c298ce8e405038b00 (patch) | |
tree | a2ed86beba410150bb41e35917239dce64cf688c /config.c | |
parent | 9dc70cbc54194ec248321acd488bbaeefa41c5eb (diff) |
Config: multiple occurences of lines is not an error.
As we now support config directories it is helpful if
lines are allowed to occur multiple times with one
over-riding the other.
So stop giving warnings when later lines are ignored.
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'config.c')
-rw-r--r-- | config.c | 22 |
1 files changed, 5 insertions, 17 deletions
@@ -507,13 +507,9 @@ void mailline(char *line) { char *w; - for (w=dl_next(line); w != line ; w=dl_next(w)) { + for (w=dl_next(line); w != line ; w=dl_next(w)) if (alert_email == NULL) alert_email = xstrdup(w); - else - pr_err("excess address on MAIL line: %s - ignored\n", - w); - } } static char *alert_mail_from = NULL; @@ -540,13 +536,9 @@ void programline(char *line) { char *w; - for (w=dl_next(line); w != line ; w=dl_next(w)) { + for (w=dl_next(line); w != line ; w=dl_next(w)) if (alert_program == NULL) alert_program = xstrdup(w); - else - pr_err("excess program on PROGRAM line: %s - ignored\n", - w); - } } static char *home_host = NULL; @@ -563,9 +555,7 @@ void homehostline(char *line) home_host = xstrdup(""); else home_host = xstrdup(w); - }else - pr_err("excess host name on HOMEHOST line: %s - ignored\n", - w); + } } } @@ -583,11 +573,9 @@ void autoline(char *line) int homehost = 0; int i; - if (auto_seen) { - pr_err("AUTO line may only be give once." - " Subsequent lines ignored\n"); + if (auto_seen) return; - } + /* Parse the 'auto' line creating policy statements for the 'auto' policy. * * The default is 'yes' but the 'auto' line might over-ride that. |