[pacman-dev] [PATCH 1/4] util/pkgbuild: guard against unset variable
Andrew Gregory
andrew.gregory.8 at gmail.com
Sat Feb 25 17:21:15 UTC 2017
Allows use under 'set -u'.
---
scripts/libmakepkg/util/pkgbuild.sh.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/libmakepkg/util/pkgbuild.sh.in b/scripts/libmakepkg/util/pkgbuild.sh.in
index 2a4bd3af..08b35f53 100644
--- a/scripts/libmakepkg/util/pkgbuild.sh.in
+++ b/scripts/libmakepkg/util/pkgbuild.sh.in
@@ -18,7 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
-[[ -n "$LIBMAKEPKG_UTIL_PKGBUILD_SH" ]] && return
+[[ -n "${LIBMAKEPKG_UTIL_PKGBUILD_SH:-}" ]] && return
LIBMAKEPKG_UTIL_PKGBUILD_SH=1
--
2.11.1
More information about the pacman-dev
mailing list