• Sam Lantinga's avatar
    Fixed bug #1027 · 7a1c6519
    Sam Lantinga authored
    Vittorio Giovara      2010-07-17 19:21:36 PDT
    
    fix the double free error
    
    in SDL_uikitview the variable 'textfield' is initialialized and set to
    autorelease.
    however in the dealloc method a second [release] is sent.
    If the textfield has not been set to nil before (with a viewDidUnload for
    example) this can lead to awful hard-to-find crashes when the SDL code
    terminates.
    
    the error message is
    -[textfield release] message sent to deallocated instance 0x4e5fa90
    
    the fix is simple, just release the object as soon as it is added to the
    subview, see attached patch
    7a1c6519
Name
Last commit
Last update
..
atomic Loading commit data...
audio Loading commit data...
cpuinfo Loading commit data...
events Loading commit data...
file Loading commit data...
haptic Loading commit data...
joystick Loading commit data...
libm Loading commit data...
loadso Loading commit data...
main Loading commit data...
power Loading commit data...
stdlib Loading commit data...
thread Loading commit data...
timer Loading commit data...
video Loading commit data...
SDL.c Loading commit data...
SDL_android.cpp Loading commit data...
SDL_android.h Loading commit data...
SDL_assert.c Loading commit data...
SDL_assert_c.h Loading commit data...
SDL_compat.c Loading commit data...
SDL_error.c Loading commit data...
SDL_error_c.h Loading commit data...
SDL_fatal.c Loading commit data...
SDL_fatal.h Loading commit data...