From: Gan Ainm Date: Wed, 22 Feb 2023 18:45:36 +0000 (+0100) Subject: Consume stdin to prevent SIGPIPE for producer X-Git-Url: https://git.corax.cc/?a=commitdiff_plain;h=a5776c4dbdf2f9253b29196566a111a9c93874c0;p=toolbox Consume stdin to prevent SIGPIPE for producer --- diff --git a/include/log.sh b/include/log.sh index b9eb3cc..c936789 100644 --- a/include/log.sh +++ b/include/log.sh @@ -87,6 +87,7 @@ _log_write() { local line if (( __log_verbosity < level )); then + [[ $# == 2 ]] && IFS="" read -r -d "" return 0 fi