diff options
author | flz <flz@FreeBSD.org> | 2009-05-19 14:26:41 +0000 |
---|---|---|
committer | flz <flz@FreeBSD.org> | 2009-05-19 14:26:41 +0000 |
commit | 74c918142dc16ddf9cbbfd50058087420d29b3c0 (patch) | |
tree | ffdd19da592462fc4ad418a215097fa0dc0b6574 /usr.sbin/pkg_install | |
parent | 960bfa71a8a6e8c40490879e82649ed63a54d4a8 (diff) | |
download | FreeBSD-src-74c918142dc16ddf9cbbfd50058087420d29b3c0.zip FreeBSD-src-74c918142dc16ddf9cbbfd50058087420d29b3c0.tar.gz |
Skip @pkgdep if there's no argument.
Submitted by: pav
MFC after: 1 week
Diffstat (limited to 'usr.sbin/pkg_install')
-rw-r--r-- | usr.sbin/pkg_install/lib/lib.h | 2 | ||||
-rw-r--r-- | usr.sbin/pkg_install/lib/plist.c | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/usr.sbin/pkg_install/lib/lib.h b/usr.sbin/pkg_install/lib/lib.h index 422912e..aef772b 100644 --- a/usr.sbin/pkg_install/lib/lib.h +++ b/usr.sbin/pkg_install/lib/lib.h @@ -105,7 +105,7 @@ * Version of the package tools - increase only when some * functionality used by bsd.port.mk is changed, added or removed */ -#define PKG_INSTALL_VERSION 20090106 +#define PKG_INSTALL_VERSION 20090519 #define PKG_WRAPCONF_FNAME "/var/db/pkg_install.conf" #define main(argc, argv) real_main(argc, argv) diff --git a/usr.sbin/pkg_install/lib/plist.c b/usr.sbin/pkg_install/lib/plist.c index 283b87f..3c87d62 100644 --- a/usr.sbin/pkg_install/lib/plist.c +++ b/usr.sbin/pkg_install/lib/plist.c @@ -285,6 +285,10 @@ read_plist(Package *pkg, FILE *fp) } if (*cp == '\0') { cp = NULL; + if (cmd == PLIST_PKGDEP) { + warnx("corrupted record (pkgdep line without argument), ignoring"); + cmd = FAIL; + } goto bottom; } if (cmd == PLIST_COMMENT && sscanf(cp, "PKG_FORMAT_REVISION:%d.%d\n", |