# HG changeset patch # User Matt Mackall # Date 1293657796 21600 # Node ID 5bcb6c9d16dbad4a99be85f70cdf2634bf2c1b40 # Parent 5d0a30fad7de1c7e75ef9457b77127c97f0c87f7 hgweb: abort if config file isn't found diff -r 5d0a30fad7de -r 5bcb6c9d16db mercurial/hgweb/hgwebdir_mod.py --- a/mercurial/hgweb/hgwebdir_mod.py Wed Dec 29 14:19:31 2010 -0600 +++ b/mercurial/hgweb/hgwebdir_mod.py Wed Dec 29 15:23:16 2010 -0600 @@ -64,6 +64,8 @@ if not isinstance(self.conf, (dict, list, tuple)): map = {'paths': 'hgweb-paths'} + if not os.path.exists(self.conf): + raise util.Abort(_('config file %s not found!') % self.conf) u.readconfig(self.conf, remap=map, trust=True) paths = u.configitems('hgweb-paths') elif isinstance(self.conf, (list, tuple)):