From fc49cf28729722a2e617f3347f70c542f834d82d Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Tue, 21 Jul 2009 18:39:48 -0400 Subject: db-update: Fix final repo_unlock Because we lock/unlock in a loop, simply remove the cleanup trap at the end of the process, and manually clean up the work dir Signed-off-by: Aaron Griffin --- db-update | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'db-update') diff --git a/db-update b/db-update index 338fb5b..525c21e 100755 --- a/db-update +++ b/db-update @@ -46,7 +46,6 @@ fi cleanup() { trap '' 0 2 - # unlock repo_unlock $reponame $current_arch rm -rf "$WORKDIR" [ "$1" ] && exit $1 @@ -54,7 +53,7 @@ cleanup() { ctrl_c() { echo "Interrupted" >&2 - cleanup 0 + cleanup 1 } die() { @@ -233,5 +232,6 @@ if [ -n "$to_add_any" ]; then /bin/rm $to_add_any fi +trap '' 0 2 rm -rf $WORKDIR # vim: set ts=4 sw=4 noet ft=sh: -- cgit v1.2.3-24-g4f1b