Created windows must be destroyed at CommonQuit().
authorMike Gorchak <lestat@i.com.ua>
Sat, 10 Oct 2009 13:21:21 +0000
changeset 3370 3e0f51e60fa2
parent 3369 71bb88152e3f
child 3371 438ba87e9578
Created windows must be destroyed at CommonQuit().
test/common.c
--- a/test/common.c	Sat Oct 10 10:02:17 2009 +0000
+++ b/test/common.c	Sat Oct 10 13:21:21 2009 +0000
@@ -1022,6 +1022,12 @@
         SDL_AudioQuit();
     }
     if (state->windows) {
+        int it;
+
+        for (it=0; it<state->num_windows; it++)
+        {
+           SDL_DestroyWindow(state->windows[it]);
+        }
         SDL_free(state->windows);
     }
     SDL_free(state);