From 3b8617b20c47ff23f976d4e90d41c6bdb6cd4bfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Lecour?= Date: Fri, 22 Mar 2019 20:04:35 +0100 Subject: [PATCH] use `grep -s` instead of redirecting stderr --- evocheck.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/evocheck.sh b/evocheck.sh index aacad32..c9a1d13 100755 --- a/evocheck.sh +++ b/evocheck.sh @@ -554,19 +554,19 @@ if is_debian; then conf=/etc/log2mail/config/default fi if is_pack_web && is_installed log2mail; then - grep -q "^file = /var/log/apache2/error.log" $conf 2>/dev/null \ + grep -s -q "^file = /var/log/apache2/error.log" $conf \ || failed "IS_LOG2MAILAPACHE" fi fi if [ "$IS_LOG2MAILMYSQL" = 1 ]; then if is_pack_web && is_installed log2mail; then - grep -q "^file = /var/log/syslog" /etc/log2mail/config/{default,mysql,mysql.conf} 2>/dev/null \ + grep -s -q "^file = /var/log/syslog" /etc/log2mail/config/{default,mysql,mysql.conf} \ || failed "IS_LOG2MAILMYSQL" fi fi if [ "$IS_LOG2MAILSQUID" = 1 ]; then if is_pack_web && is_installed log2mail; then - grep -q "^file = /var/log/squid.*/access.log" /etc/log2mail/config/* 2>/dev/null \ + grep -s -q "^file = /var/log/squid.*/access.log" /etc/log2mail/config/* \ || failed "IS_LOG2MAILSQUID" fi fi