mirror of
https://github.com/storytold/photocraft.git
synced 2026-12-03 06:31:42 +01:00
The index read kept every index in one vector and then copied it into the index surface, two bytes per pixel that the open's memory check never counted. Write the indices into the surface one band of rows at a time instead, and check that they and one band fit in free memory before reading. When they don't, no indices are recorded and Color Table falls back to the nearest entry; the open itself goes on.