Coding style cleanup
Fix the following issues reported by pylint:
C0321: More than one statement on a single line
W0622: Redefining built-in 'name'
W0612: Unused variable 'name'
W0613: Unused argument 'name'
W0102: Dangerous default value 'value' as argument
W0105: String statement has no effect
Also fixed a few cases of inconsistent indentation.
Change-Id: Ie0db839e7c57d576cff12d8c055fe87030d00744
diff --git a/subcmds/forall.py b/subcmds/forall.py
index 9436f4e..76a0268 100644
--- a/subcmds/forall.py
+++ b/subcmds/forall.py
@@ -208,7 +208,6 @@
return self.fd.fileno()
empty = True
- didout = False
errbuf = ''
p.stdin.close()
@@ -220,7 +219,7 @@
fcntl.fcntl(s.fd, fcntl.F_SETFL, flags | os.O_NONBLOCK)
while s_in:
- in_ready, out_ready, err_ready = select.select(s_in, [], [])
+ in_ready, _out_ready, _err_ready = select.select(s_in, [], [])
for s in in_ready:
buf = s.fd.read(4096)
if not buf:
@@ -229,9 +228,7 @@
continue
if not opt.verbose:
- if s.fd == p.stdout:
- didout = True
- else:
+ if s.fd != p.stdout:
errbuf += buf
continue