r55957 - /scripts/patchedit
potyl-guest at users.alioth.debian.org
potyl-guest at users.alioth.debian.org
Sun Apr 11 15:32:17 UTC 2010
Author: potyl-guest
Date: Sun Apr 11 15:31:59 2010
New Revision: 55957
URL: http://svn.debian.org/wsvn/?sc=1&rev=55957
Log:
Handle 'Subject' headers (long description is outside of the structured fields)
Modified:
scripts/patchedit
Modified: scripts/patchedit
URL: http://svn.debian.org/wsvn/scripts/patchedit?rev=55957&op=diff
==============================================================================
--- scripts/patchedit (original)
+++ scripts/patchedit Sun Apr 11 15:31:59 2010
@@ -253,7 +253,7 @@
my %patch_content;
open(my $patch_fh, '<', $patch) or die 'failed to open "'.$patch.'" - '.$!;
- my $key;
+ my $key = '';
my $header_end = 0;
while (my $line = <$patch_fh>) {
@@ -267,9 +267,10 @@
$patch_content{'_patch'} .= $line;
next;
}
-
- my $value;
- if (($key, $value) = $line =~ m/^(\S+) : \s+ (.+) $/xms) {
+
+ if ($line =~ m/^(\S+) : \s+ (.+) $/xms) {
+ my $value;
+ ($key, $value) = ($1, $2);
# New field start
die 'key "_patch" not allowed'
if $key eq '_patch';
@@ -278,7 +279,7 @@
next;
}
- if ($line =~ m/^ /) {
+ if ($line =~ m/^ / or $key eq 'Subject') {
# Previous field not over
$patch_content{$key} .= $line;
next;
More information about the Pkg-perl-cvs-commits
mailing list