summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrillig <rillig>2008-01-01 13:44:11 +0000
committerrillig <rillig>2008-01-01 13:44:11 +0000
commitec2caa354e0e7f3ab601764a43782f0af4a17513 (patch)
tree9ddbb16765ce038e9164f91098f02c4879a6ce07
parent6d467a40f9174892bc870b6740d18bb2f252d820 (diff)
downloadpkgsrc-ec2caa354e0e7f3ab601764a43782f0af4a17513.tar.gz
All characters in PLIST files are relevant, so make trailing white-space
an error. Who would ever want to install files whose name ends in white-space?
-rw-r--r--pkgtools/pkglint/files/pkglint.pl8
1 files changed, 6 insertions, 2 deletions
diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl
index d634f4d3cfb..13db7d2b1a9 100644
--- a/pkgtools/pkglint/files/pkglint.pl
+++ b/pkgtools/pkglint/files/pkglint.pl
@@ -1,5 +1,5 @@
#! @PERL@
-# $NetBSD: pkglint.pl,v 1.742 2007/12/22 22:27:17 rillig Exp $
+# $NetBSD: pkglint.pl,v 1.743 2008/01/01 13:44:11 rillig Exp $
#
# pkglint - static analyzer and checker for pkgsrc packages
@@ -7403,7 +7403,11 @@ sub checkfile_PLIST($) {
foreach my $line (@{$lines}) {
my $text = $line->text;
- checkline_trailing_whitespace($line);
+ if ($text =~ /\s$/) {
+ $line->log_error("pkgsrc does not support filenames ending in white-space.");
+ $line->explain_error(
+"Each character in the PLIST is relevant, even trailing white-space.");
+ }
# @foo directives.
if ($text =~ /^(?:\$\{[\w_]+\})?\@([a-z-]+)\s+(.*)/) {