tst_test.sh: Implement ROD_BASE in C

It appears to be impossible to write ROD_BASE correctly in the shell
library. That is because the $@ gets passed to the function and then
parsed in a loop. Because of that the parameters in $@ are evaluated
several times which yield disasterous results if there are any special
characters included such as dollar sign, whitespaces, backslashes, etc.

So this patch rewrites the ROD_BASE as tst_rod C helper that understands
stdout/stdin/stderr redirection and apart from that just copies the rest
of the parameters and calls execvp().

After the change inwoking awk (for instance awk '{print $1}') works with
ROD as well.

Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
4 files changed