svn commit: r349874 - in head/ports-mgmt/pkg: . files
Antoine Brodin
antoine at FreeBSD.org
Tue Apr 1 18:34:03 UTC 2014
Author: antoine
Date: Tue Apr 1 18:34:03 2014
New Revision: 349874
URL: http://svnweb.freebsd.org/changeset/ports/349874
QAT: https://qat.redports.org/buildarchive/r349874/
Log:
Detect invalid packages that list directories as a file in plist
Exp-run by: bdrewery
With hat: portmgr
Added:
head/ports-mgmt/pkg/files/patch-libpkg__pkg_ports.c (contents, props changed)
Modified:
head/ports-mgmt/pkg/Makefile
Modified: head/ports-mgmt/pkg/Makefile
==============================================================================
--- head/ports-mgmt/pkg/Makefile Tue Apr 1 18:29:09 2014 (r349873)
+++ head/ports-mgmt/pkg/Makefile Tue Apr 1 18:34:03 2014 (r349874)
@@ -2,6 +2,7 @@
PORTNAME= pkg
DISTVERSION= 1.2.7
+PORTREVISION= 1
CATEGORIES= ports-mgmt
MASTER_SITES= \
http://files.etoilebsd.net/${PORTNAME}/ \
Added: head/ports-mgmt/pkg/files/patch-libpkg__pkg_ports.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/ports-mgmt/pkg/files/patch-libpkg__pkg_ports.c Tue Apr 1 18:34:03 2014 (r349874)
@@ -0,0 +1,18 @@
+--- ./libpkg/pkg_ports.c.orig 2014-03-15 13:15:46.000000000 +0000
++++ ./libpkg/pkg_ports.c 2014-04-01 18:20:02.000000000 +0000
+@@ -318,9 +318,14 @@
+ buf = NULL;
+ regular = false;
+
+- if (S_ISREG(st.st_mode))
++ if (S_ISDIR(st.st_mode)) {
++ pkg_emit_error("Plist error, directory listed as a file: %s", line);
++ free_file_attr(a);
++ return (EPKG_FATAL);
++ } else if (S_ISREG(st.st_mode))
+ regular = true;
+
++
+ /* special case for hardlinks */
+ if (st.st_nlink > 1)
+ regular = is_hardlink(p->hardlinks, &st);
More information about the svn-ports-head
mailing list