summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsj <sj@openoffice.org>2010-01-11 12:28:07 +0100
committersj <sj@openoffice.org>2010-01-11 12:28:07 +0100
commit81f4386da532ba62e5e2381e57485197ce5da0bf (patch)
tree2dee0a4d12df93baa57974490380a6cdf464a952
parent5ea66a47f68665b5fd16b02188b85f64db2e3866 (diff)
impress181: #i74384# correctly interpreting maxcolor value vor ppm (taking care also for pbp)
-rw-r--r--goodies/source/filter.vcl/ipbm/ipbm.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/goodies/source/filter.vcl/ipbm/ipbm.cxx b/goodies/source/filter.vcl/ipbm/ipbm.cxx
index c0b0f6012116..3c30dd0c2ba3 100644
--- a/goodies/source/filter.vcl/ipbm/ipbm.cxx
+++ b/goodies/source/filter.vcl/ipbm/ipbm.cxx
@@ -172,6 +172,7 @@ BOOL PBMReader::ImplReadHeader()
*mpPBM >> nID[ 0 ] >> nID[ 1 ];
if ( nID[ 0 ] != 'P' )
return FALSE;
+ mnMaxVal = mnWidth = mnHeight = 0;
switch ( nID[ 1 ] )
{
case '1' :
@@ -179,6 +180,7 @@ BOOL PBMReader::ImplReadHeader()
case '4' :
mnMode = 0;
nMax = 2; // number of parameters in Header
+ mnMaxVal = 1;
break;
case '2' :
mbRaw = FALSE;
@@ -195,9 +197,6 @@ BOOL PBMReader::ImplReadHeader()
default:
return FALSE;
}
-
- mnMaxVal = mnWidth = mnHeight = 0;
-
while ( bFinished == FALSE )
{
if ( mpPBM->GetError() )