comparison mercurial/subrepo.py @ 41516:d65519e5dd04

py3: remove unneeded fsencode() from gitsubrepo Here p.stdout isn't a TextIO. read() must return bytes.
author Yuya Nishihara <yuya@tcha.org>
date Sat, 02 Feb 2019 15:21:35 +0900
parents fa7d4e6a0c98
children 549f956ba2a9
comparison
equal deleted inserted replaced
41515:7dc160a57025 41516:d65519e5dd04
1284 close_fds=procutil.closefds, 1284 close_fds=procutil.closefds,
1285 stdout=subprocess.PIPE, stderr=errpipe) 1285 stdout=subprocess.PIPE, stderr=errpipe)
1286 if stream: 1286 if stream:
1287 return p.stdout, None 1287 return p.stdout, None
1288 1288
1289 retdata = pycompat.fsencode(p.stdout.read().strip()) 1289 retdata = p.stdout.read().strip()
1290 # wait for the child to exit to avoid race condition. 1290 # wait for the child to exit to avoid race condition.
1291 p.wait() 1291 p.wait()
1292 1292
1293 if p.returncode != 0 and p.returncode != 1: 1293 if p.returncode != 0 and p.returncode != 1:
1294 # there are certain error codes that are ok 1294 # there are certain error codes that are ok