plugin: Always initialize GIL state
authorThibault Saunier <thibault.saunier@osg.samsung.com>
Sun, 30 Jul 2017 03:05:22 +0000 (23:05 -0400)
committerThibault Saunier <thibault.saunier@osg.samsung.com>
Sun, 30 Jul 2017 03:05:24 +0000 (23:05 -0400)
gcc warns about possibly unintialized use of it

(even if it can't actually happen)

plugin/gstpythonplugin.c

index 99e6d82..d695a45 100644 (file)
@@ -208,7 +208,7 @@ gst_python_plugin_load (GstPlugin * plugin)
 static gboolean
 plugin_init (GstPlugin * plugin)
 {
-  PyGILState_STATE state;
+  PyGILState_STATE state = 0;
   PyObject *gi, *require_version, *args, *gst, *dict, *pyplugin;
   gboolean we_initialized = FALSE;
   GModule *libpython;