// Purpose: wxImage PCX handler
// Author: Guillermo Rodriguez Garcia <guille@iies.es>
// Version: 1.1
-// CVS-ID: $Id$
// Copyright: (c) 1999 Guillermo Rodriguez Garcia
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
image->Create(width, height);
- if (!image->Ok())
+ if (!image->IsOk())
return wxPCX_MEMERR;
if ((p = (unsigned char *) malloc(bytesperline * nplanes)) == NULL)
// according to PCX specs) and allocate space for one complete
// scanline.
- if (!image->Ok())
+ if (!image->IsOk())
return wxPCX_INVFORMAT;
width = image->GetWidth();
if (!CanRead(stream))
{
if (verbose)
+ {
wxLogError(_("PCX: this is not a PCX file."));
+ }
return false;
}
bool wxPCXHandler::DoCanRead( wxInputStream& stream )
{
- unsigned char c = stream.GetC();
+ unsigned char c = stream.GetC(); // it's ok to modify the stream position here
if ( !stream )
return false;