From 7d1a160e51e3705fc901c7b5150913d726b58f0b Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Wed, 13 Mar 2019 18:53:34 -0400 Subject: _ob_get_system_path(): Protect against DATADIR with "%" --- (limited to 'lib/metadata') diff --git a/lib/metadata/proteanos.sh b/lib/metadata/proteanos.sh index 2519433..d61d976 100644 --- a/lib/metadata/proteanos.sh +++ b/lib/metadata/proteanos.sh @@ -136,15 +136,15 @@ _ob_get_system_path() 'buildflags') # arch [ ${#} -eq 1 ] || _ob_abort - printf "${DATADIR}/opkbuild/buildflags/%s" "${1}" + printf '%s/opkbuild/buildflags/%s' "${DATADIR}" "${1}" ;; 'platconf') # source version plat [ ${#} -eq 3 ] || _ob_abort ob_parse_version -u 'pkgver' "${2}" - printf "${DATADIR}/platconf/%s/%s\n" "${3}" "${1}" - printf "${DATADIR}/platconf/%s/%s_%s\n" "${3}" "${1}" \ - "${pkgver}" + printf '%s/platconf/%s/%s\n' "${DATADIR}" "${3}" "${1}" + printf '%s/platconf/%s/%s_%s\n' "${DATADIR}" \ + "${3}" "${1}" "${pkgver}" ;; esac -- cgit v0.9.1