On Thu, Mar 31, 2016 at 09:52:22AM -0400, Lance Richardson wrote:
> When using the default user shell in FreeBSD and NetBSD and executing
> a test in which the app name parameter to OVS_APP_EXIT_AND_WAIT
> contains backticks (e.g. "`pwd`/unixctl"), TMPPID expands to:
> 
>     `cat "$OVS_RUNDIR"/"`pwd`"/unixctl.pid 2>/dev/null`
> 
> This results in an "unterminated quoted string" syntax error from
> the shell.
> 
> Correct this by replacing backticks with $(...) in OVS_APP_EXIT_AND_WAIT.
> Verified via "make check" under NetBSD 7 and Fedora 23.
> 
> Fixes: f9b11f2a09b4 ("tests: Make OVS_APP_EXIT_AND_WAIT() wait for process 
> termination")
> Reported-by: Aaron Conole <[email protected]>
> Signed-off-by: Lance Richardson <[email protected]>

Applied, thanks!

> -  [TMPPID=`cat "$OVS_RUNDIR"/$1.pid 2>/dev/null`
> +  [TMPPID=$(cat "$OVS_RUNDIR"/$1.pid 2>/dev/null)

I wonder whether "read TMPPID < "$OVS_RUNDIR"/$1.pid 2>/dev/null" would
be more straightforward?  But no one ever uses "read"...
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to