+2006-04-04 Tim-Philipp Müller <tim at centricular dot net>
+
+ Patch by: Paolo Borelli <pborelli at katamail dot com>
+
+ * gst/gstplugin.c: (gst_plugin_finalize), (gst_plugin_class_init),
+ (gst_plugin_check_license):
+ minor clean-ups: G_DEFINE_TYPE already takes care of the
+ parent_class stuff, no need to do it twice. Mark array of
+ license strings as constant. (#337103)
+
2006-04-04 Michael Smith <msmith@fluendo.com>
* tools/gst-inspect.c: (print_element_list):
* QPL: http://www.trolltech.com/licenses/qpl.html
* MPL: http://www.opensource.org/licenses/mozilla1.1.php
*/
-static gchar *valid_licenses[] = {
+static const gchar *valid_licenses[] = {
"LGPL", /* GNU Lesser General Public License */
"GPL", /* GNU General Public License */
"QPL", /* Trolltech Qt Public License */
G_DEFINE_TYPE (GstPlugin, gst_plugin, GST_TYPE_OBJECT);
-static GstObjectClass *parent_class = NULL;
-
static void
gst_plugin_init (GstPlugin * plugin)
{
g_free (plugin->basename);
gst_plugin_desc_free (&plugin->desc);
- G_OBJECT_CLASS (parent_class)->finalize (object);
+ G_OBJECT_CLASS (gst_plugin_parent_class)->finalize (object);
}
static void
gst_plugin_class_init (GstPluginClass * klass)
{
- parent_class = g_type_class_ref (GST_TYPE_OBJECT);
-
G_OBJECT_CLASS (klass)->finalize = GST_DEBUG_FUNCPTR (gst_plugin_finalize);
}
static gboolean
gst_plugin_check_license (const gchar * license)
{
- gchar **check_license = valid_licenses;
+ const gchar **check_license = valid_licenses;
g_assert (check_license);