Original Post
Hi, I have a code like this:
void** Data = new (void*)[1];
Data[0] = create_bitmap(400,400); Then I do random stuff with this bitmap, it works fine, for example if I want to draw it then I just write draw_sprite(Buffer,(BITMAP*)Data[0],100,100); At the end of the game, I want to deallocate this whole thing. I do it like this: destroy_bitmap((BITMAP*)Data[0]); <-- error occurs here
delete[] Data; So why does it crash when I use delete_bitmap()? Any ideas? Please no replies like "don't use void**" ;)