[dpdk-dev,v2,1/2] devtools: improve kernel script execution check

Message ID 1524139203-92094-1-git-send-email-juhamatti.kuusisaari@coriant.com (mailing list archive)
State Accepted, archived
Delegated to: Thomas Monjalon
Headers

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

  Handle properly a case where DPDK_PATCH_PATH is set
to point to a directory.

Signed-off-by: Juhamatti Kuusisaari <juhamatti.kuusisaari@coriant.com>
---
 devtools/checkpatches.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Ferruh Yigit April 19, 2018, 1:21 p.m. UTC | #1
On 4/19/2018 1:00 PM, Juhamatti Kuusisaari wrote:
> Handle properly a case where DPDK_PATCH_PATH is set
> to point to a directory.
> 
> Signed-off-by: Juhamatti Kuusisaari <juhamatti.kuusisaari@coriant.com>

For series,
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
  
Thomas Monjalon May 22, 2018, 9:34 p.m. UTC | #2
19/04/2018 15:21, Ferruh Yigit:
> On 4/19/2018 1:00 PM, Juhamatti Kuusisaari wrote:
> > Handle properly a case where DPDK_PATCH_PATH is set
> > to point to a directory.
> > 
> > Signed-off-by: Juhamatti Kuusisaari <juhamatti.kuusisaari@coriant.com>
> 
> For series,
> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>

Applied, thanks
  

Patch

diff --git a/devtools/checkpatches.sh b/devtools/checkpatches.sh
index 7676a6b..2bb5458 100755
--- a/devtools/checkpatches.sh
+++ b/devtools/checkpatches.sh
@@ -75,7 +75,7 @@  while getopts hn:qv ARG ; do
 done
 shift $(($OPTIND - 1))
 
-if [ ! -x "$DPDK_CHECKPATCH_PATH" ] ; then
+if [ ! -f "$DPDK_CHECKPATCH_PATH" ] || [ ! -x "$DPDK_CHECKPATCH_PATH" ] ; then
 	print_usage >&2
 	echo
 	echo 'Cannot execute DPDK_CHECKPATCH_PATH' >&2