1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-10-31 15:45:03 -04:00

updpkgsums: avoid exec'ing awk, so the trap actually works

Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
Dave Reisner 2014-11-04 08:10:21 -05:00 committed by Allan McRae
parent bd744d067d
commit 167a598265

View File

@ -82,7 +82,7 @@ fi
export BUILDDIR=$(mktemp -d --tmpdir updpkgsums.XXXXXX)
trap "rm -rf '$BUILDDIR'" EXIT
newsums=$(makepkg -g -p "$buildfile") && rm -f "$buildfile" &&
exec awk -v newsums="$newsums" '
awk -v newsums="$newsums" '
/^[[:blank:]]*(md|sha)[[:digit:]]+sums(_[^=]+)?=/,/\)[[:blank:]]*(#.*)?$/ {
if (!w) {
print newsums