Subject: Re: netpbm problems since version 10.31
To: None <adam@NetBSD.org>
From: Jukka Salmi <j+nbsd@2006.salmi.ch>
List: tech-pkg
Date: 02/22/2006 18:40:05
--6c2NcOVqGQ03X4Wi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Hi,

according to Bryan Henderson this is a bug in netpbm. The attached
patch (sent to me by Bryan in private email) fixes it for me; it will
be included in the next netpbm release. Maybe you could add it as a
pkgsrc patch until then?


Cheers, Jukka

Jukka Salmi --> tech-pkg (2006-02-21 00:00:22 +0100):
> Hi,
> 
> I'm having problems with graphics/netpbm-10.31 built from current
> pkgsrc (running on -current and NetBSD 2): trying to convert a xwd
> image to pnm using xwdtopnm(1) results in totally a black image. Using
> netpbm-10.30 this works fine.
> 
> Any hints what could have caused this regression?
> 
> 
> TIA, Jukka
> 
> -- 
> bashian roulette:
> $ ((RANDOM%6)) || rm -rf ~

-- 
bashian roulette:
$ ((RANDOM%6)) || rm -rf ~

--6c2NcOVqGQ03X4Wi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="xwdtopnm.c.patch"

--- converter/other/xwdtopnm.c.orig	2005-12-15 04:45:59.000000000 +0100
+++ converter/other/xwdtopnm.c	2006-02-22 17:46:54.000000000 +0100
@@ -988,7 +988,7 @@
                     (rdrP->itemBuffer >> nBitsToLeave) & bitsToTakeMask;
             } else {
                 bitsToTake = rdrP->itemBuffer & bitsToTakeMask;
-                bitsToTake >>= nBitsToTake;
+                rdrP->itemBuffer >>= nBitsToTake;
             }                
             /* Shift the bits into the right end of the accumulator */
             pixel <<= nBitsToTake;

--6c2NcOVqGQ03X4Wi--