Skip to content

Commit

Permalink
Fixed memory leak in game controller test program.
Browse files Browse the repository at this point in the history
  • Loading branch information
philippwiesemann committed May 5, 2016
1 parent 63f2ec8 commit 6a9a8b6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/testgamecontroller.c
Expand Up @@ -181,6 +181,8 @@ WatchGameController(SDL_GameController * gamecontroller)
window = SDL_CreateWindow(title, SDL_WINDOWPOS_CENTERED,
SDL_WINDOWPOS_CENTERED, SCREEN_WIDTH,
SCREEN_HEIGHT, 0);
SDL_free(title);
title = NULL;
if (window == NULL) {
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Couldn't create window: %s\n", SDL_GetError());
return SDL_FALSE;
Expand Down

0 comments on commit 6a9a8b6

Please sign in to comment.