po5 / thumbfast

High-performance on-the-fly thumbnailer script for mpv
Mozilla Public License 2.0
760 stars 34 forks source link

Suppress error message when mpv exits #71

Closed N-R-K closed 1 year ago

N-R-K commented 1 year ago

Currently whenever mpv exits, the following error message is printed:

[thumbfast] /tmp/thumbfast17446.run: line 5: read: read error: 3: Connection reset by peer

Might be worthwhile to suppress it if mpv exited normally. Or suppressing it unconditionally could be an option as well:

- [...] & while read -r -u "$MPV_IPC_FD"; do :; done; fi
+ [...] & while read -r -u "$MPV_IPC_FD" 2>/dev/null; do :; done; fi