comparison mercurial/sshserver.py @ 26587:56b2bcea2529

error: get Abort from 'error' instead of 'util' The home of 'Abort' is 'error' not 'util' however, a lot of code seems to be confused about that and gives all the credit to 'util' instead of the hardworking 'error'. In a spirit of equity, we break the cycle of injustice and give back to 'error' the respect it deserves. And screw that 'util' poser. For great justice.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Thu, 08 Oct 2015 12:55:45 -0700
parents 72b36785d7f4
children 98e8313dcd9e
comparison
equal deleted inserted replaced
26586:d51c658d3f04 26587:56b2bcea2529
10 10
11 import os 11 import os
12 import sys 12 import sys
13 13
14 from . import ( 14 from . import (
15 error,
15 hook, 16 hook,
16 util, 17 util,
17 wireproto, 18 wireproto,
18 ) 19 )
19 20
37 keys = args.split() 38 keys = args.split()
38 for n in xrange(len(keys)): 39 for n in xrange(len(keys)):
39 argline = self.fin.readline()[:-1] 40 argline = self.fin.readline()[:-1]
40 arg, l = argline.split() 41 arg, l = argline.split()
41 if arg not in keys: 42 if arg not in keys:
42 raise util.Abort("unexpected parameter %r" % arg) 43 raise error.Abort("unexpected parameter %r" % arg)
43 if arg == '*': 44 if arg == '*':
44 star = {} 45 star = {}
45 for k in xrange(int(l)): 46 for k in xrange(int(l)):
46 argline = self.fin.readline()[:-1] 47 argline = self.fin.readline()[:-1]
47 arg, l = argline.split() 48 arg, l = argline.split()