From c947d1575fd0affd3a923fe6cb81ae1ceaa289eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Thu, 28 Nov 2019 21:28:07 +0100 Subject: core: exit makedist.sh script if command "cd" failed --- tools/makedist.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/makedist.sh b/tools/makedist.sh index 2bedd755d..eb7a2d25c 100755 --- a/tools/makedist.sh +++ b/tools/makedist.sh @@ -52,10 +52,10 @@ if [ $# -ge 2 ]; then TREEISH=$2 fi if [ $# -ge 3 ]; then - OUTPATH=$(cd "$3"; pwd) + OUTPATH=$(cd "$3" || exit 1; pwd) fi -cd "${ROOT_DIR}" +cd "${ROOT_DIR}" || exit 1 PREFIX="weechat-${VERSION}/" FILE="${OUTPATH}/weechat-${VERSION}.tar" -- cgit v1.2.3