diff options
author | obrien <obrien@FreeBSD.org> | 2008-03-19 14:46:59 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2008-03-19 14:46:59 +0000 |
commit | c54c20f64254351041b8ea9719450e4d774ac0a5 (patch) | |
tree | 0ae354b8af76926a31947d53202545980b36afe4 /contrib/cvs/src/parseinfo.c | |
parent | 5f43f46b30a84be45042a4dd83992110d7588aad (diff) | |
download | FreeBSD-src-c54c20f64254351041b8ea9719450e4d774ac0a5.zip FreeBSD-src-c54c20f64254351041b8ea9719450e4d774ac0a5.tar.gz |
Import of 1.11 branch snapshot - using the 10-March-2008 code base.
Diffstat (limited to 'contrib/cvs/src/parseinfo.c')
-rw-r--r-- | contrib/cvs/src/parseinfo.c | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/contrib/cvs/src/parseinfo.c b/contrib/cvs/src/parseinfo.c index 0fe9c33..feccc71 100644 --- a/contrib/cvs/src/parseinfo.c +++ b/contrib/cvs/src/parseinfo.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 1986-2005 The Free Software Foundation, Inc. + * Copyright (C) 1986-2008 The Free Software Foundation, Inc. * * Portions Copyright (C) 1998-2005 Derek Price, Ximbiot <http://ximbiot.com>, * and others. @@ -245,6 +245,7 @@ parse_config (cvsroot) /* FIXME-reentrancy: If we do a multi-threaded server, this would need to go to the per-connection data structures. */ static int parsed = 0; + int ignore_unknown_config_keys = 0; /* Authentication code and serve_root might both want to call us. Let this happen smoothly. */ @@ -415,6 +416,23 @@ warning: this CVS does not support PreservePermissions"); else if (strcmp (p, "stat") == 0) RereadLogAfterVerify = LOGMSG_REREAD_STAT; } + else if (strcmp (line, "IgnoreUnknownConfigKeys") == 0) + { + if (strcmp (p, "no") == 0 || strcmp (p, "false") == 0 + || strcmp (p, "off") == 0 || strcmp (p, "0") == 0) + ignore_unknown_config_keys = 0; + else if (strcmp (p, "yes") == 0 || strcmp (p, "true") == 0 + || strcmp (p, "on") == 0 || strcmp (p, "1") == 0) + ignore_unknown_config_keys = 1; + else + { + error (0, 0, "%s: unrecognized value '%s' for '%s'", + infopath, p, line); + goto error_return; + } + } + else if (ignore_unknown_config_keys) + ; else { /* We may be dealing with a keyword which was added in a |