impress181: #i74384# correctly interpreting maxcolor value vor ppm (taking care also for pbp)
This commit is contained in:
parent
5ea66a47f6
commit
81f4386da5
1 changed files with 2 additions and 3 deletions
|
@ -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() )
|
||||
|
|
Loading…
Reference in a new issue