mercurial/server.py
changeset 40841 368ecbf734af
parent 38823 e7aa113b14f7
child 40842 82210d88d814
equal deleted inserted replaced
40840:6a75363f834a 40841:368ecbf734af
   153 }
   153 }
   154 
   154 
   155 def _createcmdservice(ui, repo, opts):
   155 def _createcmdservice(ui, repo, opts):
   156     mode = opts['cmdserver']
   156     mode = opts['cmdserver']
   157     try:
   157     try:
   158         return _cmdservicemap[mode](ui, repo, opts)
   158         servicefn = _cmdservicemap[mode]
   159     except KeyError:
   159     except KeyError:
   160         raise error.Abort(_('unknown mode %s') % mode)
   160         raise error.Abort(_('unknown mode %s') % mode)
       
   161     commandserver.setuplogging(ui)
       
   162     return servicefn(ui, repo, opts)
   161 
   163 
   162 def _createhgwebservice(ui, repo, opts):
   164 def _createhgwebservice(ui, repo, opts):
   163     # this way we can check if something was given in the command-line
   165     # this way we can check if something was given in the command-line
   164     if opts.get('port'):
   166     if opts.get('port'):
   165         opts['port'] = util.getport(opts.get('port'))
   167         opts['port'] = util.getport(opts.get('port'))