Change palette_t allocation so that it uses matching new/delete operators.