Commit 4679195dbf9fd80f07ca4f6100d7f590e7c8afb9

Philipp Wiesemann 2015-07-06T21:02:20

Fixed memory leak in test harness. Found by Cppcheck.

1
2
3
4
5
6
7
8
9
10
11
12
diff --git a/src/test/SDL_test_harness.c b/src/test/SDL_test_harness.c
index aa965f4..6dde93f 100644
--- a/src/test/SDL_test_harness.c
+++ b/src/test/SDL_test_harness.c
@@ -484,6 +484,7 @@ int SDLTest_RunSuites(SDLTest_TestSuiteReference *testSuites[], const char *user
         if (suiteFilter == 0 && testFilter == 0) {
             SDLTest_LogError("Filter '%s' did not match any test suite/case.", filter);
             SDLTest_Log("Exit code: 2");
+            SDL_free(failedTests);
             return 2;
         }
     }