Error in BGRAGifFormat while loading attached file. "RunError(204)". Application crashed. LazPaint also crash while loading this file. Other viewers show this file correctly. I can give more gif-files that do this crash.
Sorry for bad english.
Anonymous
Solution found!
GIFCodeTableSize increased from 4096 to 32768. Line 104 in BGRAGifFormat.pas. Works fine.
Thank you all for a wonderful project :-)
Thank you! I have applied the change (32768 when loading, but still 4096 when writing to maximize compatibility)
I found a way is better.
The data from the table with an index greater than 4096 are not used. You just need to add a check for overflow. That is now AddStr2Tab function (line 242) will record and further the index 4096, as variable stridx not limited. To avoid recording in a memory cell outside the table (which leads to a crash), I propose to add a function AddStr2Tab first line this condition:
Works good. A GIFCodeTableSize size in 4096 - it is right, because it is no longer necessary.
The result AddStr2Tab:
Indeed, it works fine. I have applied this on SVN.
I am happy to contribute to this wonderful project. :-)