1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

PY3 pure build fix some str/bytes wobblies

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Noel Power 2018-11-24 15:27:21 +00:00 committed by Noel Power
parent c316738f26
commit a7cb10e4b4

View File

@ -97,7 +97,7 @@ def add_tarfile(tar, fname, abspath, basedir):
tinfo.gid = 0
tinfo.uname = 'root'
tinfo.gname = 'root'
fh = open(abspath)
fh = open(abspath, "rb")
tar.addfile(tinfo, fileobj=fh)
fh.close()
@ -119,7 +119,7 @@ def vcs_dir_contents(path):
repo = os.path.dirname(repo)
if repo == "/":
raise Exception("unsupported or no vcs for %s" % path)
return Utils.cmd_output(ls_files_cmd, cwd=cwd, env=env).split('\n')
return Utils.cmd_output(ls_files_cmd, cwd=cwd, env=env).decode('utf8').split('\n')
def dist(appname='', version=''):