From 5667d34182fa1911d58ba88f688dfef6d5a5e4c5 Mon Sep 17 00:00:00 2001 From: Julien Isorce Date: Fri, 13 Mar 2015 09:07:16 +0000 Subject: [PATCH] examples: initialize NSApp at the beginning --- tests/examples/gl/cocoa/cocoa-videooverlay.m | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/examples/gl/cocoa/cocoa-videooverlay.m b/tests/examples/gl/cocoa/cocoa-videooverlay.m index 78c19690a5..a783c5672a 100755 --- a/tests/examples/gl/cocoa/cocoa-videooverlay.m +++ b/tests/examples/gl/cocoa/cocoa-videooverlay.m @@ -166,6 +166,9 @@ int main(int argc, char **argv) NSRect rect; MainWindow *window=nil; + pool = [[NSAutoreleasePool alloc] init]; + [NSApplication sharedApplication]; + g_print("app created\n"); gst_init (&argc, &argv); @@ -192,9 +195,6 @@ int main(int argc, char **argv) if (!ok) g_warning("could not link videosrc to videosink\n"); - pool = [[NSAutoreleasePool alloc] init]; - [NSApplication sharedApplication]; - rect.origin.x = 0; rect.origin.y = 0; rect.size.width = width; rect.size.height = height;