Package: netpbm Version: 2:10.0-12.2+b1 Severity: normal Tags: upstream patch
When invoked without a filename argument, pnmquant fails. Upon inspection, this is because pnmquant is a perl script that performs the two-pass pnmcolormap pnmremap sequence, and it does not bother to save stdin for the second pass. A patch is attached. Alternatively, one could simply change the documentation to indicate that pnmquant must receive a filename argument. (BTW, I'm not sure whether the "this code is in the public domain" license of pnmquant is OK, but I'm too lazy to file a separate bug report on this.) -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (950, 'testing'), (650, 'unstable'), (500, 'stable') Architecture: i386 (i686) Kernel: Linux 2.6.32-5-686 (SMP w/4 CPU cores) Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968) Shell: /bin/sh linked to /bin/bash Versions of packages netpbm depends on: ii libc6 2.11.2-2 Embedded GNU C Library: Shared lib ii libjpeg62 6b1-1 The Independent JPEG Group's JPEG ii libnetpbm10 2:10.0-12.2+b1 Graphics conversion tools shared l ii libpng12-0 1.2.44-1 PNG library - runtime ii libtiff4 3.9.4-1 Tag Image File Format (TIFF) libra ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime Versions of packages netpbm recommends: ii ghostscript 8.71~dfsg2-3 The GPL Ghostscript PostScript/PDF netpbm suggests no packages. -- no debconf information --- pnmquant.dist 2010-11-03 10:27:30.000000000 -0700 +++ pnmquant 2010-11-03 21:58:20.000000000 -0700 @@ -9,6 +9,7 @@ use Getopt::Long; use File::Temp "tempfile"; use File::Spec; +use File::Copy; my ($TRUE, $FALSE) = (1,0); @@ -39,7 +40,13 @@ if (@ARGV > 1) { $infile = $ARGV[1]; } else { - $infile = "-"; + my ($savefileFh, $savefileSpec) = + tempfile("pnmquantSaveXXXX", + SUFFIX => ".pnm", + UNLINK => $TRUE, + DIR => File::Spec->tmpdir()); + copy(\*STDIN, $savefileFh); + $infile = $savefileSpec; } my $averageOpt; -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org