diff options
Diffstat (limited to 'intern/ghost/test')
-rw-r--r-- | intern/ghost/test/gears/GHOST_Test.cpp | 5 | ||||
-rw-r--r-- | intern/ghost/test/multitest/MultiTest.c | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/intern/ghost/test/gears/GHOST_Test.cpp b/intern/ghost/test/gears/GHOST_Test.cpp index 1e641a8643c..6709956e2dd 100644 --- a/intern/ghost/test/gears/GHOST_Test.cpp +++ b/intern/ghost/test/gears/GHOST_Test.cpp @@ -715,13 +715,16 @@ int main(int /*argc*/, char ** /*argv*/) // Add the application as event consumer fSystem->addEventConsumer(&app); - + // Enter main loop while (!app.m_exitRequested) { //printf("main: loop\n"); fSystem->processEvents(true); fSystem->dispatchEvents(); } + + // Remove so ghost doesn't do a double free + fSystem->removeEventConsumer(&app); } // Dispose the system diff --git a/intern/ghost/test/multitest/MultiTest.c b/intern/ghost/test/multitest/MultiTest.c index 2d0afcf671c..e9d5880651e 100644 --- a/intern/ghost/test/multitest/MultiTest.c +++ b/intern/ghost/test/multitest/MultiTest.c @@ -931,11 +931,13 @@ void multitestapp_free(MultiTestApp *app) int main(int argc, char **argv) { + MultiTestApp *app; + #ifndef USE_BMF BLF_init(11, 72); #endif - MultiTestApp *app = multitestapp_new(); + app = multitestapp_new(); multitestapp_run(app); multitestapp_free(app); |