From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by dpdk.org (Postfix) with ESMTP id 529C329AC for ; Fri, 20 Jul 2018 13:41:12 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id BCFBD211E5; Fri, 20 Jul 2018 07:41:11 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Fri, 20 Jul 2018 07:41:11 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:date:from:message-id:subject:to:x-me-sender:x-me-sender :x-sasl-enc; s=mesmtp; bh=2TDQ8zmms1wMmZ5Lu+p7Q60TZkTJdJRuZFDjND 4bcNQ=; b=T8lMZeGDJ/9Ii0mRRstOCf1Wz80aej2Qi5Fpn871LOLz4+/oma5EXK BJNF4NN5BEcGJlRPpBc0iEYqusShyf0yMpzKL6FpHGhWzZeBqQ6ugSD0k0FUMMS0 qtTQOG4l1JJ7WXx26Czgrmt7MN7kyq8TizwInVfJhEj5J4UnJ2Dhg= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=2TDQ8zmms1wMmZ5Lu +p7Q60TZkTJdJRuZFDjND4bcNQ=; b=rYCeEImg3RJU9P6UATEFhuNEp+Z5Dg8P3 qWeIku9FBFdLUWYFreoLXWy+yioLVQnNAbcgaRcs5JwPZm6H2bMr4YJaSdDj3tpq 6NDLPbpgjhF4UG9LFemxlGEJnV4AgJmTX6fVk1g4g27YyYR9uOdN8NSmeYGwG98M GZBJ3qoteM3BaxdZqR2+S421uvcNevS3eFbznMvhw7HJdrw6pU8RT+1CptvhxKxO OY+Pe7G8wXqsUakkHcJ8H68AM9xqgq8CUaTlNW1RqR0pBSasGmtVqthaEWqVwbI2 vMx3nSuHmDn6DeFSOEo1K9xhNo3yxi9HbeK5I8T1wo1j6ygoHbKKg== X-ME-Proxy: X-ME-Sender: Received: from xps.monjalon.net (unknown [207.232.18.42]) by mail.messagingengine.com (Postfix) with ESMTPA id 7A7CC1025D; Fri, 20 Jul 2018 07:41:08 -0400 (EDT) From: Thomas Monjalon To: nhorman@tuxdriver.com Cc: dev@dpdk.org Date: Fri, 20 Jul 2018 13:41:03 +0200 Message-Id: <20180720114103.18211-1-thomas@monjalon.net> X-Mailer: git-send-email 2.17.1 Subject: [dpdk-dev] [PATCH] devtools: fix checkpatch for filename with space X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2018 11:41:12 -0000 If the patch filename or the temporary file path have a space in their name, the script checkpatches.sh does not work. The variables for the filenames must be enclosed in quotes in order to preserve spaces. Fixes: 4bec48184e33 ("devtools: add checks for ABI symbol addition") Signed-off-by: Thomas Monjalon --- Strangely, I did a fix for check-symbol-change.sh and I forgot to fix checkpatches.sh. --- devtools/checkpatches.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/devtools/checkpatches.sh b/devtools/checkpatches.sh index 1439bce94..e97a4f2c9 100755 --- a/devtools/checkpatches.sh +++ b/devtools/checkpatches.sh @@ -25,7 +25,7 @@ NEW_TYPEDEFS,COMPARISON_TO_NULL" clean_tmp_files() { if echo $tmpinput | grep -q '^checkpatches\.' ; then - rm -f $tmpinput + rm -f "$tmpinput" fi } @@ -77,13 +77,13 @@ check () { # elif [ -n "$2" ] ; then tmpinput=$(mktemp checkpatches.XXXXXX) git format-patch --find-renames \ - --no-stat --stdout -1 $commit > $tmpinput + --no-stat --stdout -1 $commit > "$tmpinput" else tmpinput=$(mktemp checkpatches.XXXXXX) - cat > $tmpinput + cat > "$tmpinput" fi - report=$($DPDK_CHECKPATCH_PATH $options $tmpinput 2>/dev/null) + report=$($DPDK_CHECKPATCH_PATH $options "$tmpinput" 2>/dev/null) if [ $? -ne 0 ] ; then $verbose || printf '\n### %s\n\n' "$3" printf '%s\n' "$report" | sed -n '1,/^total:.*lines checked$/p' -- 2.17.1