summaryrefslogtreecommitdiff
path: root/etc/common
diff options
context:
space:
mode:
Diffstat (limited to 'etc/common')
-rw-r--r--etc/common2
1 files changed, 1 insertions, 1 deletions
diff --git a/etc/common b/etc/common
index 687c5fe..0501240 100644
--- a/etc/common
+++ b/etc/common
@@ -181,7 +181,7 @@ log () {
# to the address configured in MAILTO (if non-empty)
error () {
log "$@"
- if [ -z "${MAILTO}" ]; then
+ if [ -n "${MAILTO}" ]; then
echo "$@" | mail -e -s "[$PROGRAM@$(hostname -s)] ERROR [$$]" ${MAILTO}
fi
}