From 90af29cda926cf818fa52b780ab444860c251846 Mon Sep 17 00:00:00 2001 From: michael Date: Mon, 2 May 2011 19:05:53 +0000 Subject: [PATCH] * Patch from Colin Western to read B/W bitmaps with padding bits (19237) git-svn-id: trunk@17390 - --- packages/fcl-image/src/fpreadpnm.pp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/fcl-image/src/fpreadpnm.pp b/packages/fcl-image/src/fpreadpnm.pp index 754ea10c51..3b9d6a56c0 100644 --- a/packages/fcl-image/src/fpreadpnm.pp +++ b/packages/fcl-image/src/fpreadpnm.pp @@ -229,13 +229,13 @@ Var L:=P^; for j:=0 to 7 do begin - if odd(L) - then + if x < FWidth then + if odd(L) then Img.Colors[x,Row]:=colBlack else Img.Colors[x,Row]:=colWhite; - L:=L shr 1; - dec(x); + L:=L shr 1; + dec(x); end; Inc(P); Inc(x,16);