fix zeroconf handling for hgwebdir (error found by pychecker)
authorBenoit Boissinot <benoit.boissinot@ens-lyon.org>
Tue, 28 Oct 2008 20:23:22 +0100
changeset 7282 6541696b5f66
parent 7281 f96c20e9b56a
child 7283 b19c0200c90b
fix zeroconf handling for hgwebdir (error found by pychecker)
hgext/zeroconf/__init__.py
--- a/hgext/zeroconf/__init__.py	Tue Oct 28 20:14:45 2008 +0100
+++ b/hgext/zeroconf/__init__.py	Tue Oct 28 20:23:22 2008 +0100
@@ -82,12 +82,11 @@
 
 class hgwebdirzc(hgwebdir_mod.hgwebdir):
     def run(self):
-        print os.environ
         for r, p in self.repos:
             u = ui.ui(parentui=self.parentui)
-            u.readconfig(os.path.join(path, '.hg', 'hgrc'))
+            u.readconfig(os.path.join(p, '.hg', 'hgrc'))
             n = os.path.basename(r)
-            publish(n, "hgweb", p, int(repo.ui.config("web", "port", 8000)))
+            publish(n, "hgweb", p, int(u.config("web", "port", 8000)))
         return super(hgwebdirzc, self).run()
 
 # listen