--- a/hgwebdir.cgi Fri Feb 01 10:31:15 2008 +0100
+++ b/hgwebdir.cgi Fri Feb 01 13:09:45 2008 -0800
@@ -22,6 +22,7 @@
#os.environ["HGENCODING"] = "UTF-8"
from mercurial.hgweb.hgwebdir_mod import hgwebdir
+from mercurial import dispatch, ui
import mercurial.hgweb.wsgicgi as wsgicgi
# The config file looks like this. You can have paths to individual
@@ -43,5 +44,5 @@
# Alternatively you can pass a list of ('virtual/path', '/real/path') tuples
# or use a dictionary with entries like 'virtual/path': '/real/path'
-application = hgwebdir('hgweb.config')
-wsgicgi.launch(application)
+u = ui.ui(report_untrusted=False, interactive=False)
+dispatch.profiled(u, lambda: wsgicgi.launch(hgwebdir('hgweb.config', u)))