It was using out-of-bounds data to manipulate the palette, and a
missing break caused it to change palette again immediately. Still,
even after this change I had the impression that the temporary
palette was visible for a bit longer in DOSBox. Could be my
imagination, though.