mirror of
https://github.com/samba-team/samba.git
synced 2025-11-27 08:23:49 +03:00
samba-tool visualize: remove py2 compat for colour calculations
io.StringIO has .isatty(); the old cStringIO did not, Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Joseph Sutton <josephsutton@catalyst.net.nz>
This commit is contained in:
committed by
Douglas Bagnall
parent
6ced3d2151
commit
6160e956b5
@@ -162,9 +162,6 @@ class GraphCommand(Command):
|
||||
return None
|
||||
if isinstance(output, str) and output != '-':
|
||||
return None
|
||||
if not hasattr(self.outf, 'isatty'):
|
||||
# not a real file, perhaps cStringIO in testing
|
||||
return None
|
||||
if not self.outf.isatty():
|
||||
return None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user