diff options
| author | 2020-02-24 18:17:03 +0000 | |
|---|---|---|
| committer | 2020-02-24 18:17:03 +0000 | |
| commit | 2a2fe00c4fe39f2976a0b7e4339a17d86ade54ab (patch) | |
| tree | c0917613fbb43b483057ad2739882798132271fb /bin | |
| parent | support reading from stdin in bin/bitbot-log (diff) | |
| signature | ||
handle stdout being closed before we're finished
Diffstat (limited to 'bin')
| -rwxr-xr-x | bin/bitbot-log | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/bitbot-log b/bin/bitbot-log index f067ff9f..73c11859 100755 --- a/bin/bitbot-log +++ b/bin/bitbot-log @@ -62,4 +62,7 @@ for line in lines: printable = line if not printable == None: - print(printable) + try: + sys.stdout.write("%s\n" % printable) + except BrokenPipeError: + break |
