Bug#188965: dpkg-scanpackages fails getting .deb md5sum
Package: dpkg-dev
Version: 1.10.9
Severity: important
Debian: 3.0 unstable
dpkg-scanpackages doesn't create the Packages file because of an error
into the script
that interpretates the normal output of md5sum as "Strange text".
Command run:
# dpkg-scanpackages debian/pool override
Output obtained:
Strange text from `md5sum <
debian/pool/main/3/3270/xfonts-x3270-misc_3.2.17-2_all.deb':
`e70e6bcc33d9094ef70dbdb4fbd7b546 -'
#
Suggested patch (obtained through diff -Naur):
--- patch start here!!! ---
--- /usr/bin/dpkg-scanpackages 2001-10-09 19:29:27.000000000 +0200
+++ dpkg-scanpackages 2003-04-14 09:37:40.000000000 +0200
@@ -115,8 +115,8 @@
open(C,"md5sum <$fn |") || die "$fn $!";
chop($_=<C>); close(C); $? and die "\`md5sum < $fn' exited with
$?\n";
- /^[0-9a-f]{32}$/ or die "Strange text from \`md5sum < $fn':
\`$_'\n";
- $tv{'MD5sum'}= $_;
+ /^[0-9a-f]{32} -$/ or die "Strange text from \`md5sum < $fn':
\`$_'\n";
+ $tv{'MD5sum'}= substr($_,0,32);
@stat= stat($fn) or die "Couldn't stat $fn: $!\n";
$stat[7] or die "$fn is empty\n";
--- patch end here!!! ---
After applying this patch all works as expected.
Arcangelo Labianca
arclab@dm.uniba.it
Reply to: