fix Save_PI1()

the color cycling information was always overwriting the last 32 bytes
so the last 16 pixels were almost always saved black
This commit is contained in:
Thomas Bernard 2018-06-28 14:30:39 +02:00
parent 413346b0df
commit 8a018fdb82

View File

@ -1697,10 +1697,14 @@ void Save_PI1(T_IO_Context * context)
ptr+=8;
}
}
PI1_save_ranges(context, buffer, 32034);
if (Write_bytes(file,buffer,32034))
{
if (context->Color_cycles)
{
PI1_save_ranges(context, buffer, 32);
Write_bytes(file,buffer,32);
}
fclose(file);
}
else // Error d'écriture (disque plein ou protégé)