[SDL] SDL2 error on iOS (doublefree)

Jeremy Jurksztowicz jurksztowicz at gmail.com
Tue Feb 7 08:11:22 PST 2012

I can't find the bug report, I think I actually just posted on the forum
right after Sam left for a little while. Anyways, I'm sure I did mention
the bug, and I even have it patched in my own sources, but what is really
weird is that the 2.0 source I just downloaded looks like there was an
attempt to prevent the double release because of the following lines in

        [data->uiscreenmode retain];  // once for the desktop_mode

        [data->uiscreenmode retain];  // once for the current_mode

Further on down in UIKit_VideoQuit there is:



        for (j = 0; j < display->num_display_modes; j++) {

            SDL_DisplayMode *mode = &display->display_modes[j];



>From what I see here it looks like there are potentially 3 releases but I
haven't really figured out how the display->display_modes array is
populated. For the record, I'm using a very old patched 1.3 in my iOS game
and haven't been bitten by this double release, however, I was being hit by
it before I manually patched the source. I'll try and figure out the
deal-ee-yo when I can squeeze some time in.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20120208/043dc4eb/attachment-0008.htm>

More information about the SDL mailing list