From 509af95c9281549cc93805aca19ed6e7f8de024a Mon Sep 17 00:00:00 2001 From: David Sterba Date: Fri, 15 Sep 2017 16:18:00 +0200 Subject: btrfs-progs: tests: make sure _is_file_or_command does not get confused The test cli/007-check-force reports something like: $ type -p '--string that starts with dashes' bash: type: --: invalid option Add the option/argument separator. Signed-off-by: David Sterba --- tests/common | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/common b/tests/common index 1c098e8e..eb525a4d 100644 --- a/tests/common +++ b/tests/common @@ -35,7 +35,7 @@ _is_file_or_command() if [ -f "$msg" -o -d "$msg" -o -b "$msg" ]; then return 0 fi - msg=$(type -p "$msg") + msg=$(type -p -- "$msg") if [ -f "$msg" ]; then return 0 fi -- cgit v1.2.3