FS/XFS testing framework
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Zhaolei <zhaolei@cn.fujitsu.com>
Cc: fstests@vger.kernel.org
Subject: Re: [PATCH 1/2] xfstests: fix a typo in _require_block_device()
Date: Wed, 18 Feb 2015 12:21:39 +1100	[thread overview]
Message-ID: <20150218012139.GO4251@dastard> (raw)
In-Reply-To: <1424069440-14957-1-git-send-email-zhaolei@cn.fujitsu.com>

On Mon, Feb 16, 2015 at 02:50:39PM +0800, Zhaolei wrote:
> From: Zhao Lei <zhaolei@cn.fujitsu.com>
> 
> We need to check "$1" instead "$SCRATCH_DEV" in this function.
> And make tabs same with other code.
> 
> Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
> ---
>  common/rc | 14 +++++++-------
>  1 file changed, 7 insertions(+), 7 deletions(-)
> 
> diff --git a/common/rc b/common/rc
> index 7449a1d..76522d4 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -1284,13 +1284,13 @@ _require_command()
>  # $1 - device
>  _require_block_device()
>  {
> -	if [ -z "$1" ]; then
> -		echo "Usage: _require_block_device <dev>" 1>&2
> -		exit 1
> -	fi
> -	if [ "`_is_block_dev $SCRATCH_DEV`" == "" ]; then
> -		_notrun "require $1 to be valid block disk"
> -	fi
> +    if [ -z "$1" ]; then
> +	echo "Usage: _require_block_device <dev>" 1>&2
> +	exit 1
> +    fi
> +    if [ "`_is_block_dev $1`" == "" ]; then
> +	_notrun "require $1 to be valid block disk"
> +    fi
>  }

The change is fine - the reformating of the code is not. 8 space
tabs for all new code and all new modifications, please.

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  parent reply	other threads:[~2015-02-18  1:21 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-16  6:50 [PATCH 1/2] xfstests: fix a typo in _require_block_device() Zhaolei
2015-02-16  6:50 ` [PATCH 2/2] Fix warning of "Usage: _is_block_dev dev" Zhaolei
2015-02-18  5:37   ` Dave Chinner
2015-02-26  9:05     ` Zhao Lei
2015-02-26  9:30     ` Zhao Lei
2015-02-18  1:21 ` Dave Chinner [this message]
2015-02-18 10:21   ` [PATCH 1/2] xfstests: fix a typo in _require_block_device() Andrew Price
2015-02-18 22:02     ` Dave Chinner
2015-02-26  9:52       ` Lukáš Czerner
2015-02-26 11:41         ` Andrew Price

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150218012139.GO4251@dastard \
    --to=david@fromorbit.com \
    --cc=fstests@vger.kernel.org \
    --cc=zhaolei@cn.fujitsu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox