* [gentoo-commits] portage r13582 - main/trunk/bin
@ 2009-05-01 21:43 Zac Medico (zmedico)
0 siblings, 0 replies; only message in thread
From: Zac Medico (zmedico) @ 2009-05-01 21:43 UTC (permalink / raw
To: gentoo-commits
Author: zmedico
Date: 2009-05-01 21:43:32 +0000 (Fri, 01 May 2009)
New Revision: 13582
Modified:
main/trunk/bin/isolated-functions.sh
Log:
Make elog functions use read -r when splitting lines, so that backslashes
intended for display will not be eaten.
Modified: main/trunk/bin/isolated-functions.sh
===================================================================
--- main/trunk/bin/isolated-functions.sh 2009-05-01 19:11:50 UTC (rev 13581)
+++ main/trunk/bin/isolated-functions.sh 2009-05-01 21:43:32 UTC (rev 13582)
@@ -182,7 +182,7 @@
return 1
;;
esac
- echo -e "$@" | while read ; do
+ echo -e "$@" | while read -r ; do
echo "$messagetype $REPLY" >> \
"${T}/logging/${EBUILD_PHASE:-other}"
done
@@ -192,8 +192,8 @@
eqawarn() {
elog_base QA "$*"
[[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
- echo -e "$@" | while read ; do
- vecho -e " $WARN*$NORMAL $REPLY" >&2
+ echo -e "$@" | while read -r ; do
+ vecho " $WARN*$NORMAL $REPLY" >&2
done
LAST_E_CMD="eqawarn"
return 0
@@ -202,8 +202,8 @@
elog() {
elog_base LOG "$*"
[[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
- echo -e "$@" | while read ; do
- echo -e " $GOOD*$NORMAL $REPLY"
+ echo -e "$@" | while read -r ; do
+ echo " $GOOD*$NORMAL $REPLY"
done
LAST_E_CMD="elog"
return 0
@@ -230,8 +230,8 @@
einfo() {
elog_base INFO "$*"
[[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
- echo -e "$@" | while read ; do
- echo -e " $GOOD*$NORMAL $REPLY"
+ echo -e "$@" | while read -r ; do
+ echo " $GOOD*$NORMAL $REPLY"
done
LAST_E_CMD="einfo"
return 0
@@ -248,8 +248,8 @@
ewarn() {
elog_base WARN "$*"
[[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
- echo -e "$@" | while read ; do
- echo -e " $WARN*$NORMAL $RC_INDENTATION$REPLY" >&2
+ echo -e "$@" | while read -r ; do
+ echo " $WARN*$NORMAL $RC_INDENTATION$REPLY" >&2
done
LAST_E_CMD="ewarn"
return 0
@@ -258,8 +258,8 @@
eerror() {
elog_base ERROR "$*"
[[ ${RC_ENDCOL} != "yes" && ${LAST_E_CMD} == "ebegin" ]] && echo
- echo -e "$@" | while read ; do
- echo -e " $BAD*$NORMAL $RC_INDENTATION$REPLY" >&2
+ echo -e "$@" | while read -r ; do
+ echo " $BAD*$NORMAL $RC_INDENTATION$REPLY" >&2
done
LAST_E_CMD="eerror"
return 0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-05-01 21:43 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-01 21:43 [gentoo-commits] portage r13582 - main/trunk/bin Zac Medico (zmedico)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox