ext/a52dec/gsta52dec.c: Call the channel positions get_type() method in plugin_init...
authorJan Schmidt <thaytan@mad.scientist.com>
Fri, 23 Jun 2006 16:29:41 +0000 (16:29 +0000)
committerJan Schmidt <thaytan@mad.scientist.com>
Fri, 23 Jun 2006 16:29:41 +0000 (16:29 +0000)
Original commit message from CVS:
* ext/a52dec/gsta52dec.c: (plugin_init):
Call the channel positions get_type() method in plugin_init
to ensure that it isn't simultaneously called later from
multiple threads.

ChangeLog
ext/a52dec/gsta52dec.c

index 0785c11..84ec2ee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2006-06-23  Jan Schmidt  <thaytan@mad.scientist.com>
+
+       * ext/a52dec/gsta52dec.c: (plugin_init):
+         Call the channel positions get_type() method in plugin_init 
+         to ensure that it isn't simultaneously called later from 
+         multiple threads.
+
 2006-06-23  Tim-Philipp Müller  <tim at centricular dot net>
 
        * gst/mpegstream/gstmpegpacketize.c:
index 579ae5c..1336252 100644 (file)
@@ -750,6 +750,10 @@ gst_a52dec_get_property (GObject * object, guint prop_id, GValue * value,
 static gboolean
 plugin_init (GstPlugin * plugin)
 {
+  /* ensure GstAudioChannelPosition type is registered */
+  if (!gst_audio_channel_position_get_type ())
+    return FALSE;
+
   if (!gst_element_register (plugin, "a52dec", GST_RANK_SECONDARY,
           GST_TYPE_A52DEC))
     return FALSE;