--- a/mercurial/hgweb/server.py Mon Jul 25 15:38:10 2011 -0500
+++ b/mercurial/hgweb/server.py Mon Jul 25 15:38:46 2011 -0500
@@ -248,7 +248,7 @@
from threading import activeCount
_mixin = SocketServer.ThreadingMixIn
except ImportError:
- if hasattr(os, "fork"):
+ if util.safehasattr(os, "fork"):
_mixin = SocketServer.ForkingMixIn
else:
class _mixin(object):
--- a/mercurial/hgweb/webutil.py Mon Jul 25 15:38:10 2011 -0500
+++ b/mercurial/hgweb/webutil.py Mon Jul 25 15:38:46 2011 -0500
@@ -72,7 +72,7 @@
d['date'] = s.date()
d['description'] = s.description()
d['branch'] = s.branch()
- if hasattr(s, 'path'):
+ if util.safehasattr(s, 'path'):
d['file'] = s.path()
yield d