summaryrefslogtreecommitdiff
path: root/pkgtools
diff options
context:
space:
mode:
authorrillig <rillig>2006-05-31 08:10:45 +0000
committerrillig <rillig>2006-05-31 08:10:45 +0000
commit260fe4fbb2bc80e2f47b2df712cdd9f35a525ab4 (patch)
tree640c91ea53e5adc535804b50624db87f1a52811e /pkgtools
parent7deeee01892e2d4206f88d3a7d9fb4c85cb7cf8b (diff)
downloadpkgsrc-260fe4fbb2bc80e2f47b2df712cdd9f35a525ab4.tar.gz
Fixed indentation level in checkline_mk_vartype.
Diffstat (limited to 'pkgtools')
-rw-r--r--pkgtools/pkglint/files/pkglint.pl58
1 files changed, 29 insertions, 29 deletions
diff --git a/pkgtools/pkglint/files/pkglint.pl b/pkgtools/pkglint/files/pkglint.pl
index c05bcdadc40..61b61da2734 100644
--- a/pkgtools/pkglint/files/pkglint.pl
+++ b/pkgtools/pkglint/files/pkglint.pl
@@ -1,5 +1,5 @@
#! @PERL@
-# $NetBSD: pkglint.pl,v 1.592 2006/05/31 06:35:52 rillig Exp $
+# $NetBSD: pkglint.pl,v 1.593 2006/05/31 08:10:45 rillig Exp $
#
# pkglint - static analyzer and checker for pkgsrc packages
@@ -4062,42 +4062,42 @@ sub checkline_mk_vartype($$$$$) {
}
}
- if (!defined($type)) {
- # Cannot check anything if the type is not known.
+ if (!defined($type)) {
+ # Cannot check anything if the type is not known.
- } elsif ($op eq "!=") {
- $opt_debug and $line->log_info("Use of !=: ${value}");
+ } elsif ($op eq "!=") {
+ $opt_debug and $line->log_info("Use of !=: ${value}");
- } elsif ($type->kind_of_list != LK_NONE) {
- my (@words, $rest);
+ } elsif ($type->kind_of_list != LK_NONE) {
+ my (@words, $rest);
- if ($type->kind_of_list == LK_INTERNAL) {
- @words = split(qr"\s+", $value);
- $rest = "";
- } else {
- @words = ();
- $rest = $value;
- while ($rest =~ s/^$regex_shellword//) {
- my ($word) = ($1);
- last if ($word =~ qr"^#");
- push(@words, $1);
- }
- }
-
- foreach my $word (@words) {
- checkline_mk_vartype_basic($line, $varname, $type->basic_type, $op, $word, $comment, true);
- if ($type->kind_of_list != LK_INTERNAL) {
- checkline_mk_shellword($line, $word, true);
- }
+ if ($type->kind_of_list == LK_INTERNAL) {
+ @words = split(qr"\s+", $value);
+ $rest = "";
+ } else {
+ @words = ();
+ $rest = $value;
+ while ($rest =~ s/^$regex_shellword//) {
+ my ($word) = ($1);
+ last if ($word =~ qr"^#");
+ push(@words, $1);
}
+ }
- if ($rest !~ qr"^\s*$") {
- $opt_debug and $line->log_warning("Invalid shell word \"${value}\" at the end.");
+ foreach my $word (@words) {
+ checkline_mk_vartype_basic($line, $varname, $type->basic_type, $op, $word, $comment, true);
+ if ($type->kind_of_list != LK_INTERNAL) {
+ checkline_mk_shellword($line, $word, true);
}
+ }
- } else {
- checkline_mk_vartype_basic($line, $varname, $type->basic_type, $op, $value, $comment, !type_should_be_quoted($type));
+ if ($rest !~ qr"^\s*$") {
+ $opt_debug and $line->log_warning("Invalid shell word \"${value}\" at the end.");
}
+
+ } else {
+ checkline_mk_vartype_basic($line, $varname, $type->basic_type, $op, $value, $comment, !type_should_be_quoted($type));
+ }
}
sub checkline_mk_varassign($$$$$) {