Fixed memory leak in game controller test program.
authorPhilipp Wiesemann <philipp.wiesemann@arcor.de>
Thu, 05 May 2016 22:05:21 +0200
changeset 10162562b819414b5
parent 10161 c0c399499591
child 10163 0f89301aae00
Fixed memory leak in game controller test program.
test/testgamecontroller.c
     1.1 --- a/test/testgamecontroller.c	Thu May 05 22:04:16 2016 +0200
     1.2 +++ b/test/testgamecontroller.c	Thu May 05 22:05:21 2016 +0200
     1.3 @@ -181,6 +181,8 @@
     1.4      window = SDL_CreateWindow(title, SDL_WINDOWPOS_CENTERED,
     1.5                                SDL_WINDOWPOS_CENTERED, SCREEN_WIDTH,
     1.6                                SCREEN_HEIGHT, 0);
     1.7 +    SDL_free(title);
     1.8 +    title = NULL;
     1.9      if (window == NULL) {
    1.10          SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Couldn't create window: %s\n", SDL_GetError());
    1.11          return SDL_FALSE;