comparison mercurial/hgweb/server.py @ 30082:ebc03e64548a

hgweb: fix the MRO in Python 3 object should appear at the end, otherwise it tries to pre-empt the other new-style classes in the MRO, resulting in an unresolvable MRO in Py3. We still need to include object because otherwise in 2.7 we end up with an old-style class if threading is not supported, new-style if it is.
author Martijn Pieters <mjpieters@fb.com>
date Sat, 08 Oct 2016 19:11:19 +0200
parents 075146e85bb6
children dd3dd80fca10
comparison
equal deleted inserted replaced
30081:dd0ff715a82c 30082:ebc03e64548a
261 def openlog(opt, default): 261 def openlog(opt, default):
262 if opt and opt != '-': 262 if opt and opt != '-':
263 return open(opt, 'a') 263 return open(opt, 'a')
264 return default 264 return default
265 265
266 class MercurialHTTPServer(object, _mixin, httpservermod.httpserver): 266 class MercurialHTTPServer(_mixin, httpservermod.httpserver, object):
267 267
268 # SO_REUSEADDR has broken semantics on windows 268 # SO_REUSEADDR has broken semantics on windows
269 if os.name == 'nt': 269 if os.name == 'nt':
270 allow_reuse_address = 0 270 allow_reuse_address = 0
271 271