From patchwork Fri May 25 07:44:06 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixin Zhang X-Patchwork-Id: 920267 X-Patchwork-Delegate: petr.vorel@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.linux.it (client-ip=213.254.12.146; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=intel.com Received: from picard.linux.it (picard.linux.it [213.254.12.146]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40sdYd0qXVz9s15 for ; Fri, 25 May 2018 17:44:20 +1000 (AEST) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id CAF353E6B1A for ; Fri, 25 May 2018 09:44:16 +0200 (CEST) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-6.smtp.seeweb.it (in-6.smtp.seeweb.it [217.194.8.6]) by picard.linux.it (Postfix) with ESMTP id C04BF3E6AF2 for ; Fri, 25 May 2018 09:44:13 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-6.smtp.seeweb.it (Postfix) with ESMTPS id 25E96141A872 for ; Fri, 25 May 2018 09:44:10 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 May 2018 00:44:08 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,439,1520924400"; d="scan'208";a="44116763" Received: from yixin-desktop.sh.intel.com ([10.239.161.27]) by orsmga008.jf.intel.com with ESMTP; 25 May 2018 00:44:07 -0700 From: Yixin Zhang To: ltp@lists.linux.it Date: Fri, 25 May 2018 15:44:06 +0800 Message-Id: <20180525074406.24422-1-yixin.zhang@intel.com> X-Mailer: git-send-email 2.14.1 X-Virus-Scanned: clamav-milter 0.99.2 at in-6.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=-0.0 required=7.0 tests=SPF_PASS autolearn=disabled version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on in-6.smtp.seeweb.it Cc: Yixin Zhang Subject: [LTP] [PATCH ltp] controllers/cpuset/cpuset_regression_test.sh: fix shellcheck error X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" testcases/kernel/controllers/cpuset/cpuset_regression_test.sh:89:10:error: -n doesn't work with unquoted arguments. Quote or use [[ ]]. [SC2070] Signed-off-by: Yixin Zhang --- testcases/kernel/controllers/cpuset/cpuset_regression_test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testcases/kernel/controllers/cpuset/cpuset_regression_test.sh b/testcases/kernel/controllers/cpuset/cpuset_regression_test.sh index 4a104a3ad..249f16a76 100755 --- a/testcases/kernel/controllers/cpuset/cpuset_regression_test.sh +++ b/testcases/kernel/controllers/cpuset/cpuset_regression_test.sh @@ -86,7 +86,7 @@ cleanup() rmdir ${root_cpuset_dir}/testdir fi - if [ -n ${cpu_exclusive_value} -a ${cpu_exclusive_value} -ne 1 ]; then + if [ -n "${cpu_exclusive_value}" ] && [ ${cpu_exclusive_value} -ne 1 ]; then # Need to flush, or may be output: # "write error: Device or resource busy" sync