
KR> diff -r 9ff301e463a4 -r 33df023c86f1 provider-register.sh KR> --- a/provider-register.sh Wed Nov 12 14:22:50 2008 -0800 KR> +++ b/provider-register.sh Wed Nov 05 15:13:38 2008 -0800 KR> @@ -233,13 +233,25 @@ KR> fi KR> if test $mofmode = 1 KR> then KR> - mymofs="$mymofs $1" KR> + tmp_mofs="$tmp_mofs $1" KR> else KR> - myregs="$myregs $1" KR> + tmp_regs="$tmp_regs $1" KR> fi KR> shift KR> done KR> - KR> + KR> + mymofs=`(for d in $tmp_mofs; do echo $d; done) | tac` KR> + if test $? != 0 KR> + then KR> + mymofs=$tmp_mofs KR> + fi KR> + KR> + myregs=`(for d in $tmp_regs; do echo $d; done) | tac` KR> + if test $? != 0 KR> + then KR> + myregs=$tmp_regs KR> + fi KR> + Instead of building the temporary list forwards and then reversing it, why not just build it in reverse? If you change this line: myregs="$myregs $1" to myregs="$1 $myregs" Won't that accomplish the goal without the dual lists, extra error path, etc? -- Dan Smith IBM Linux Technology Center Open Hypervisor Team email: danms@us.ibm.com