On Monday 17 May 2010 22:10, Douglas Mencken wrote:
> Patches welcome? Here's mine.
> License: Public domain.

> -             while read -r; do
> -                     test x"$REPLY" = x"INSERT" && REPLY="$s"
> -                     printf "%s\n" "$REPLY"
> +             while read -r reply; do
> +                     test x"$reply" = x"INSERT" && reply="$s"
> +                     printf "%s\n" "$reply"
>               done <"$src" >>"$dst.$$.tmp"
> 
>               if test -f "$dst" && cmp -s "$dst.$$.tmp" "$dst"; then
> 
> (also attached)
> It's easy, isn't it? ;)

Easy and wrong. It eats leading and trailing whitespace.
-- 
vda

_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to