The following commit has been merged in the master branch:
commit 18169a3ecac3c47d1c0cde2eaa93bce198d26421
Author: Raphaël Hertzog <[email protected]>
Date:   Wed Feb 24 19:59:29 2010 +0100

    dpkg-source, dpkg-genchanges: split Binary lines at less than 980 chars
    
    Splitting on the first space after 980 characters was not enough as
    package names can be quite long and the real limit is not 1024 chars
    but rather 992 chars for email exchange.
    
    Example of problematic changes:
    http://lists.debian.org/debian-devel-changes/2010/02/msg01090.html
    
    We now split on the last space before the 980 chars limit.

diff --git a/scripts/dpkg-genchanges.pl b/scripts/dpkg-genchanges.pl
index 4b4226f..9bdd479 100755
--- a/scripts/dpkg-genchanges.pl
+++ b/scripts/dpkg-genchanges.pl
@@ -470,7 +470,7 @@ if (!defined($fields->{'Date'})) {
 
 $fields->{'Binary'} = join(' ', map { $_->{'Package'} } 
$control->get_packages());
 # Avoid overly long line (>~1000 chars) by splitting over multiple lines
-$fields->{'Binary'} =~ s/(.{980,}?) /$1\n/g;
+$fields->{'Binary'} =~ s/(.{0,980}) /$1\n/g;
 
 unshift(@archvalues,'source') unless is_binaryonly;
 @archvalues = ('all') if $include == ARCH_INDEP;
diff --git a/scripts/dpkg-source.pl b/scripts/dpkg-source.pl
index ce528fc..0ea8cc0 100755
--- a/scripts/dpkg-source.pl
+++ b/scripts/dpkg-source.pl
@@ -288,7 +288,7 @@ if ($options{'opmode'} =~ /^(-b|--print-format)$/) {
     
     $fields->{'Binary'} = join(', ', @binarypackages);
     # Avoid overly long line (>~1000 chars) by splitting over multiple lines
-    $fields->{'Binary'} =~ s/(.{980,}?), ?/$1,\n/g;
+    $fields->{'Binary'} =~ s/(.{0,980}), ?/$1,\n/g;
 
     # Generate list of formats to try
     my @try_formats = (@cmdline_formats);

-- 
dpkg's main repository


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to