Mercurial > public > mercurial-scm > hg
comparison mercurial/chgserver.py @ 44867:8e8fd938ca07
cleanup: eliminate procutil.quotecommand()
After some compatibility code was removed, the function was the identity
function on all platforms.
author | Manuel Jacob <me@manueljacob.de> |
---|---|
date | Fri, 29 May 2020 03:56:07 +0200 |
parents | d37975386798 |
children | 3862de62d5cf |
comparison
equal
deleted
inserted
replaced
44866:5258bffdb1d6 | 44867:8e8fd938ca07 |
---|---|
318 self.in_ = in_ | 318 self.in_ = in_ |
319 self.out = out | 319 self.out = out |
320 self.channel = channel | 320 self.channel = channel |
321 | 321 |
322 def __call__(self, cmd, environ, cwd=None, type=b'system', cmdtable=None): | 322 def __call__(self, cmd, environ, cwd=None, type=b'system', cmdtable=None): |
323 args = [type, procutil.quotecommand(cmd), os.path.abspath(cwd or b'.')] | 323 args = [type, cmd, os.path.abspath(cwd or b'.')] |
324 args.extend(b'%s=%s' % (k, v) for k, v in pycompat.iteritems(environ)) | 324 args.extend(b'%s=%s' % (k, v) for k, v in pycompat.iteritems(environ)) |
325 data = b'\0'.join(args) | 325 data = b'\0'.join(args) |
326 self.out.write(struct.pack(b'>cI', self.channel, len(data))) | 326 self.out.write(struct.pack(b'>cI', self.channel, len(data))) |
327 self.out.write(data) | 327 self.out.write(data) |
328 self.out.flush() | 328 self.out.flush() |