From: Zorro Lang Date: Thu, 19 May 2016 04:30:59 +0000 (+0800) Subject: common/rc: teach _require_xfs_io_command accept multi-parameters X-Git-Tag: v2022.05.01~2508 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=a6f6e594f74a7d8a68044cba170f52e6d460be48;p=xfstests-dev.git common/rc: teach _require_xfs_io_command accept multi-parameters The $param can't be used for all command's options, for example "help pwrite" include: -Z N -- zeed the random number generator (used when writing randomly) (heh, zorry, the -s/-S arguments were already in use in pwrite) We should make param="-Z N", not only "-Z". After this patch, we can run this function as: _require_xfs_io_command pwrite -Z N Signed-off-by: Zorro Lang Reviewed-by: Christoph Hellwig Reviewed-by: Eryu Guan Signed-off-by: Eryu Guan --- diff --git a/common/rc b/common/rc index 51092a06..9c532cc1 100644 --- a/common/rc +++ b/common/rc @@ -1874,7 +1874,8 @@ _require_xfs_io_command() exit 1 fi command=$1 - param=$2 + shift + param="$*" testfile=$TEST_DIR/$$.xfs_io case $command in