Fixed problem with obfuscate.sh finding strings too long

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@5733 af4574ff-66df-0310-9fd7-8a98e5e911e0
This commit is contained in:
Bruce Dubbs 2006-03-17 18:42:50 +00:00
parent c96da0f968
commit ff5d1ee2c1

View File

@ -25,7 +25,7 @@
# Nothing like a backup plan!
#cp "$1" "$1".bak
for i in `grep -o '"mailto:.*@.*"' "$1" |sed -e 's|^"mailto:||' -e 's|"$||'`; do
for i in `grep -o '"mailto:.*@.*"' "$1" |cut -d\" -f2|sed -e 's|^mailto:||' -e 's|"$||'`; do
link=`echo $i | perl -pe 's/[^\n]/"\\\&#".ord($&)."\;"/ge'`
plaintext=`echo $i | sed -e 's|@| AT |' -e 's|\.| D0T |g'`
sed -i "s|mailto:$i|mailto:$link|" "$1"