summaryrefslogtreecommitdiff
path: root/src/pkgbuild-check-nonfree
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2017-04-20 21:50:58 -0400
committerLuke Shumaker <lukeshu@lukeshu.com>2017-04-20 22:56:14 -0400
commitd958a33c1f0e11b770481a9188cbf75cc3bfd0a5 (patch)
treeb5ae47096365863eb26a77a89af0e36b48b5ca03 /src/pkgbuild-check-nonfree
parent2d1ae58285ade402260bf5d5a4dbf42aba027fc5 (diff)
Quote unquoted strings that should probably be quoted.
These were found with the help of shellcheck. Nothing more complicated than wrapping a variable in double quotes has been done.
Diffstat (limited to 'src/pkgbuild-check-nonfree')
-rwxr-xr-xsrc/pkgbuild-check-nonfree12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/pkgbuild-check-nonfree b/src/pkgbuild-check-nonfree
index 67f07bc..d5495c7 100755
--- a/src/pkgbuild-check-nonfree
+++ b/src/pkgbuild-check-nonfree
@@ -5,7 +5,7 @@
# Copyright (C) 2011 Joseph Graham (Xylon) <joe@t67.eu>
# Copyright (C) 2010-2011 Joshua Ismael Haase Hernández (xihh) <hahj87@gmail.com>
# Copyright (C) 2010-2012 Nicolás Reynolds <fauno@parabola.nu>
-# Copyright (C) 2012-2013 Luke Shumaker <lukeshu@sbcglobal.net>
+# Copyright (C) 2012-2013, 2017 Luke Shumaker <lukeshu@sbcglobal.net>
#
# License: GNU GPLv3+
#
@@ -129,7 +129,7 @@ pkgbuild_get_pkg_str() {
local var=$2
local indirect=${!var}
- eval $(declare -f package_$pkg | sed -rn "s/^\s*${var}(\+?=)/indirect\1/p")
+ eval "$(declare -f "package_$pkg" | sed -rn "s/^\s*${var}(\+?=)/indirect\1/p")"
printf '%s' "${indirect}"
}
# Usage: eval $(pkgbuild_get_pkg_ary ${pkgname} ${varname} [$variable_name_to_set])
@@ -142,7 +142,7 @@ pkgbuild_get_pkg_ary() {
local ary="${var}[@]"
local indirect=("${!ary}")
- eval $(declare -f package_$pkg | sed -rn "s/^\s*${var}(\+?=)/indirect\1/p")
+ eval "$(declare -f "package_$pkg" | sed -rn "s/^\s*${var}(\+?=)/indirect\1/p")"
declare -p indirect|sed "s/ indirect=/ ${out}=/"
}
@@ -277,9 +277,9 @@ pkgbuild_check() (
local _pkgname _license _depends _optdepends
for _pkgname in "${pkgname[@]}"; do
msg2 'Inspecting split package pkgname=%q (%s)' "$_pkgname" "$(get_full_version "$_pkgname")"
- eval $(pkgbuild_get_pkg_ary "$_pkgname" license _license)
- eval $(pkgbuild_get_pkg_ary "$_pkgname" depends _depends)
- eval $(pkgbuild_get_pkg_ary "$_pkgname" optdepends _optdepends)
+ eval "$(pkgbuild_get_pkg_ary "$_pkgname" license _license)"
+ eval "$(pkgbuild_get_pkg_ary "$_pkgname" depends _depends)"
+ eval "$(pkgbuild_get_pkg_ary "$_pkgname" optdepends _optdepends)"
# Check if this is blacklisted
check_pkg "$_pkgname" || ret=$(($ret|$?))