From c417aa306de4329322d99f1067f97a35013610b3 Mon Sep 17 00:00:00 2001 From: Thomas Bächler Date: Thu, 29 May 2008 15:29:56 -0400 Subject: Fix EXTRAFILES in ftpdir-cleanup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Thomas Bächler Signed-off-by: Aaron Griffin --- cron-jobs/ftpdir-cleanup | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/cron-jobs/ftpdir-cleanup b/cron-jobs/ftpdir-cleanup index d6dce11..f8c1a8e 100755 --- a/cron-jobs/ftpdir-cleanup +++ b/cron-jobs/ftpdir-cleanup @@ -70,10 +70,12 @@ done cd "$ftppath" for pkg in *$PKGEXT; do pkgname="$(getpkgname $pkg)" - if [ "$pkg" != "$TMPDIR/$pkgname-*" -a "$(getpkgname $(basename $pkg))" = "$pkgname" ]; then - continue 2 - fi - EXTRAFILES="$EXTRAFILE $pkg" + for p in ${TMPDIR}/${pkgname}-*; do + if [ -d "${p}" -a "$(getpkgname $(basename ${p}))" = "${pkgname}" ]; then + continue 2 + fi + done + EXTRAFILES="$EXTRAFILES $pkg" done cd "$ftppath" -- cgit v1.2.3-24-g4f1b