summaryrefslogtreecommitdiffstats
path: root/data_hacks/run_for.py
diff options
context:
space:
mode:
Diffstat (limited to 'data_hacks/run_for.py')
-rw-r--r--data_hacks/run_for.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/data_hacks/run_for.py b/data_hacks/run_for.py
index 55c4259..1e6e26b 100644
--- a/data_hacks/run_for.py
+++ b/data_hacks/run_for.py
@@ -42,10 +42,7 @@ def getruntime(arg):
def run(runtime):
end = time.time() + runtime
- while True:
- line = sys.stdin.readline()
- if not line:
- break
+ for line in sys.stdin:
sys.stdout.write(line)
if time.time() > end:
return
@@ -62,4 +59,4 @@ if __name__ == "__main__":
if not runtime:
print usage
sys.exit(1)
- run(runtime) \ No newline at end of file
+ run(runtime)