playback-test: avoid critical on exit
authorRavi Kiran K N <ravi.kiran@samsung.com>
Fri, 18 Sep 2015 05:29:46 +0000 (10:59 +0530)
committerTim-Philipp Müller <tim@centricular.com>
Fri, 18 Sep 2015 08:02:48 +0000 (09:02 +0100)
Only free vis_entries array when not null on exit.

https://bugzilla.gnome.org/show_bug.cgi?id=755201

tests/examples/playback/playback-test.c

index 74c04e2..d458c2b 100644 (file)
@@ -3385,7 +3385,8 @@ reset_app (PlaybackApp * app)
   g_list_free (app->paths);
   g_list_foreach (app->sub_paths, (GFunc) g_free, NULL);
   g_list_free (app->sub_paths);
-  g_array_free (app->vis_entries, TRUE);
+  if (app->vis_entries)
+    g_array_free (app->vis_entries, TRUE);
   g_print ("free pipeline\n");
   gst_object_unref (app->pipeline);
 }