The Internal Field Seperator is meant for this so use it instead of reading and stripping ':' again.
Feedback? Comments? Index: rc =================================================================== RCS file: /cvs/src/etc/rc,v retrieving revision 1.508 diff -u -p -r1.508 rc --- rc 17 Jul 2017 12:02:53 -0000 1.508 +++ rc 17 Jul 2017 13:33:54 -0000 @@ -351,8 +350,8 @@ if [[ $1 == shutdown ]]; then [[ -f /etc/rc.shutdown ]] && sh /etc/rc.shutdown fi - ifconfig | while read _if _junk; do - [[ $_if == carp+([0-9]): ]] && ifconfig ${_if%:} down + ifconfig | while IFS=: read _if _junk; do + [[ $_if == carp+([0-9]) ]] && ifconfig $_if down done exit 0