Fix bug where cursor could be freed more than once
Move sprite_t to dos_sprite_t