--- a/mercurial/config.py Thu Dec 10 12:31:21 2009 +0100
+++ b/mercurial/config.py Sat Dec 12 16:46:16 2009 +0100
@@ -100,7 +100,13 @@
base = os.path.dirname(src)
inc = os.path.normpath(os.path.join(base, inc))
if include:
- include(inc, remap=remap, sections=sections)
+ try:
+ include(inc, remap=remap, sections=sections)
+ except IOError, inst:
+ msg = _("config error at %s:%d: "
+ "cannot include %s (%s)") \
+ % (src, line, inc, inst.strerror)
+ raise error.ConfigError(msg)
continue
if emptyre.match(l):
continue