summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorOkan Demirmen <okan@cvs.openbsd.org>2011-06-25 13:37:06 +0000
committerOkan Demirmen <okan@cvs.openbsd.org>2011-06-25 13:37:06 +0000
commit12020040901fda226664a9de7097a7417e3616c1 (patch)
tree3d4a322b3881a08d9c58a37775343481e5f058f2 /app
parentf7fc985572a760f3844dcc58045589d41175dbb2 (diff)
warn if we can't parse the config file on start, just like we do on reload.
part of a larger diff that was ok oga@
Diffstat (limited to 'app')
-rw-r--r--app/cwm/conf.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/cwm/conf.c b/app/cwm/conf.c
index a87ef8db6..975732cd0 100644
--- a/app/cwm/conf.c
+++ b/app/cwm/conf.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: conf.c,v 1.85 2011/06/24 06:09:26 okan Exp $
+ * $OpenBSD: conf.c,v 1.86 2011/06/25 13:37:05 okan Exp $
*/
#include <sys/param.h>
@@ -283,7 +283,8 @@ conf_setup(struct conf *c, const char *conf_file)
conf_init(c);
- (void)parse_config(c->conf_path, c);
+ if (parse_config(c->conf_path, c) == -1)
+ warnx("config file %s has errors, not loading", c->conf_path);
}
void