I had a file that displayed correctly but which I could not save. So I went
down to the code and in IFFByteStream.cpp I made the following changes
int IFFByteStream::check_id(const char *id)
// check absence of null bytes
for (i=0; i<4; i++)
if (id_<0x20 || id>0x7e)
return -2; // instead of -1 that is used also below
and in function:
IFFByteStream::get_chunk(GUTF8String &chkid, int *rawoffsetptr, int
// Check if composite
int composite = check_id(buffer);
if(composite<-1)return 0; // modification -> means that it is a null chunk
id, so skip it
if (composite < 0)
G_THROW( ERR_MSG("IFFByteStream.corrupt_id") );
And now, the file can be saved correctly. What I did is just to skip the null
id'd chunks right ?
Will there be any side effect to this ?
This is very strange.
Can you post the offending file and describe the problem more precisely?
Enough to replicate?
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.