diff options
author | David Mulder <dmulder@suse.com> | 2020-09-11 14:29:46 -0600 |
---|---|---|
committer | David Mulder <dmulder@samba.org> | 2020-10-02 14:49:36 +0000 |
commit | a3cd31532125ccb537af6cd9d27c761b7da4b03a (patch) | |
tree | 6639a07c71aa236ff87145d91799d4aedf486c39 /selftest | |
parent | 85d2ff2f0003b106ca84866b7e7893723f1dd93c (diff) | |
download | samba-a3cd31532125ccb537af6cd9d27c761b7da4b03a.tar.gz |
python2 reduction: Merge remaining compat code into common
The remaining compat code (get_string, get_bytes,
cmp) are useful helper routines which we should
simply merge into common (especially since there
is some duplication here).
Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Autobuild-User(master): David Mulder <dmulder@samba.org>
Autobuild-Date(master): Fri Oct 2 14:49:36 UTC 2020 on sn-devel-184
Diffstat (limited to 'selftest')
-rwxr-xr-x | selftest/filter-subunit | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/selftest/filter-subunit b/selftest/filter-subunit index d67fbaceb51..99e1c41e5ee 100755 --- a/selftest/filter-subunit +++ b/selftest/filter-subunit @@ -102,12 +102,8 @@ else: flapping=flapping) try: - from samba.compat import PY3 from io import TextIOWrapper as TextIOWrapper - if PY3: - forgiving_stdin = TextIOWrapper(sys.stdin.buffer, errors='ignore', encoding='utf-8') - else: - forgiving_stdin = sys.stdin + forgiving_stdin = TextIOWrapper(sys.stdin.buffer, errors='ignore', encoding='utf-8') ret = subunithelper.parse_results(msg_ops, statistics, forgiving_stdin) except subunithelper.ImmediateFail: sys.stdout.flush() |