aboutsummaryrefslogtreecommitdiffstats
path: root/security
diff options
context:
space:
mode:
authorjeh <jeh@FreeBSD.org>2004-10-28 02:13:16 +0800
committerjeh <jeh@FreeBSD.org>2004-10-28 02:13:16 +0800
commitea6b376d40e2c219d5d4c534ea449d501294dc33 (patch)
tree54e06f4b67d574c9efe9db05a6bf4e0b33b05e4d /security
parent5b3e55ecea700ea8ebadb26cd37768b1729f0adb (diff)
downloadfreebsd-ports-gnome-ea6b376d40e2c219d5d4c534ea449d501294dc33.tar.gz
freebsd-ports-gnome-ea6b376d40e2c219d5d4c534ea449d501294dc33.tar.zst
freebsd-ports-gnome-ea6b376d40e2c219d5d4c534ea449d501294dc33.zip
Remove a DAT file that didn't completely download because it is not useful
and make refetching easier
Diffstat (limited to 'security')
-rw-r--r--security/uvscan-dat/files/update_dat22
1 files changed, 11 insertions, 11 deletions
diff --git a/security/uvscan-dat/files/update_dat b/security/uvscan-dat/files/update_dat
index 772b1eb368e2..41b6d826b7b7 100644
--- a/security/uvscan-dat/files/update_dat
+++ b/security/uvscan-dat/files/update_dat
@@ -16,18 +16,18 @@ AVVER=`grep DATVersion update.ini | head -1 | cut -f2 -d= | sed -e 's/^\(4[0-9]*
# Check to make sure the requested version is "newer" then the current
if [ "$cur_AVVER" -lt "$AVVER" ]; then
- if [ ! -f dat-$AVVER.tar ]; then
- for i in *.tar ; do
- mv $i $i.old
+ for i in *.tar ; do
+ mv $i $i.old
+ done
+ if ftp http://download.nai.com/products/datfiles/4.x/nai/dat-$AVVER.tar >/dev/null ; then
+ for i in *.dat ; do
+ cp -p $i $i.bak
done
- if ftp http://download.nai.com/products/datfiles/4.x/nai/dat-$AVVER.tar >/dev/null ; then
- for i in *.dat ; do
- cp -p $i $i.bak
- done
- if tar xf dat-$AVVER.tar ; then
- rm -f *.old
- echo `date` Successfully updated AntiVirus DAT files to $AVVER
- fi
+ if tar xf dat-$AVVER.tar ; then
+ rm -f *.old
+ echo `date` Successfully updated AntiVirus DAT files to $AVVER
fi
+ else
+ rm -f dat-$AVVER.tar
fi
fi