summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorAntoine Jacoutot <ajacoutot@cvs.openbsd.org>2009-08-16 20:15:11 +0000
committerAntoine Jacoutot <ajacoutot@cvs.openbsd.org>2009-08-16 20:15:11 +0000
commit144d9dc665577d4b2c7a8d8d59b443513abb6509 (patch)
tree288597a155ccc061956858871840820e943674e8 /usr.sbin
parent3f9d803a21b20690be91130a1f0e0ac3118d033c (diff)
Properly initialize the array setting auto-upgradable files.
ok sthen@
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/sysmerge/sysmerge.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.sbin/sysmerge/sysmerge.sh b/usr.sbin/sysmerge/sysmerge.sh
index a37453136e3..03c174eae91 100644
--- a/usr.sbin/sysmerge/sysmerge.sh
+++ b/usr.sbin/sysmerge/sysmerge.sh
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $OpenBSD: sysmerge.sh,v 1.47 2009/06/28 21:08:06 ajacoutot Exp $
+# $OpenBSD: sysmerge.sh,v 1.48 2009/08/16 20:15:10 ajacoutot Exp $
#
# Copyright (c) 1998-2003 Douglas Barton <DougB@FreeBSD.org>
# Copyright (c) 2008, 2009 Antoine Jacoutot <ajacoutot@openbsd.org>
@@ -164,9 +164,12 @@ do_populate() {
for _d in ${_D}; do
CURSUM=$(cd ${DESTDIR:=/} && cksum ${_d} 2> /dev/null)
if [ -n "`grep "${CURSUM}" ${DESTDIR}/${DBDIR}/${i}`" -a -z "`grep "${CURSUM}" ${WRKDIR}/${i}`" ]; then
- set -A AUTO_UPG -- ${_d}
+ _array="${_array} ${_d}"
fi
done
+ if [ -n "${_array}" ]; then
+ set -A AUTO_UPG -- ${_array}
+ fi
# check for obsolete files
awk '{ print $3 }' ${DESTDIR}/${DBDIR}/${i} > ${WRKDIR}/new