git://git.jankratochvil.net
/
nethome.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
38bdaa3
)
Fixed excessive patches reporting.
author
lace
<>
Wed, 15 Nov 2006 23:57:33 +0000
(23:57 +0000)
committer
lace
<>
Wed, 15 Nov 2006 23:57:33 +0000
(23:57 +0000)
bin/checkspecpatch
patch
|
blob
|
history
diff --git
a/bin/checkspecpatch
b/bin/checkspecpatch
index
7f89ae9
..
994d058
100755
(executable)
--- a/
bin/checkspecpatch
+++ b/
bin/checkspecpatch
@@
-19,22
+19,27
@@
for $ARGV (@ARGV) {
my @applyno=sort { $a<=>$b; } ($file=~/^#+\s*%patch(\d+)\b/mig);
my %applyno=map(($_=>1),@applyno);
while (@source || @apply) {
my @applyno=sort { $a<=>$b; } ($file=~/^#+\s*%patch(\d+)\b/mig);
my %applyno=map(($_=>1),@applyno);
while (@source || @apply) {
- my $source=(shift @source)||"";
- my $apply =(shift @apply)||"";
+ my $source=(shift @source);
+ $source=999999 if !defined $source;
+ my $apply =(shift @apply);
+ $apply=999999 if !defined $apply;
next if $source eq $apply;
next if $source eq $apply;
- if ($
source ne "" && $apply
< $source) {
-
unshift @source,$source
;
+ if ($
apply
< $source) {
+
shift @apply
;
warn "$ARGV: excessive: ".'%'."patch$apply\n";
$rc=1;
warn "$ARGV: excessive: ".'%'."patch$apply\n";
$rc=1;
- }
- if ($apply ne "" && $source < $apply) {
- unshift @apply,$apply;
+ } elsif ($source < $apply) {
+ shift @source;
if (!$applyno{$source}) {
warn "$ARGV: excessive: Patch$source\n";
$rc=1;
} else {
warn "$ARGV: (commented ".'%'."patch$source: Patch$source)\n";
}
if (!$applyno{$source}) {
warn "$ARGV: excessive: Patch$source\n";
$rc=1;
} else {
warn "$ARGV: (commented ".'%'."patch$source: Patch$source)\n";
}
+ } else {
+ die if $apply ne $source;
+ shift @apply;
+ shift @source;
}
}
}
}
}
}