From 43210ad0726bf87ca10ce050eb2ceac5edb6bfc1 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 22 Jun 2006 17:16:46 +0000 Subject: As suggested by exg, include the einfon code inside einfo instead of using the FUNCNAME hack (FUNCNAME only works with >=bash-3.0). svn path=/main/trunk/; revision=3607 --- bin/isolated-functions.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'bin') diff --git a/bin/isolated-functions.sh b/bin/isolated-functions.sh index 0bb4fa6d5..94ff1c983 100644 --- a/bin/isolated-functions.sh +++ b/bin/isolated-functions.sh @@ -49,7 +49,9 @@ esyslog() { } einfo() { - einfon "$*" + elog_base INFO "$*" + [[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo + echo -e " ${GOOD}*${NORMAL} $*" LAST_E_CMD="einfo" return 0 } @@ -57,11 +59,7 @@ einfo() { einfon() { elog_base INFO "$*" [[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo - if [ "${FUNCNAME[1]}" == "einfo" ]; then - echo -e " ${GOOD}*${NORMAL} $*" - else - echo -ne " ${GOOD}*${NORMAL} $*" - fi + echo -ne " ${GOOD}*${NORMAL} $*" LAST_E_CMD="einfon" return 0 } -- cgit v1.2.3-1-g7c22