iterator: Fix single iterator for NULL objects and non-GTypeInstance objects
authorSebastian Dröge <sebastian.droege@collabora.co.uk>
Tue, 1 Sep 2009 05:27:25 +0000 (07:27 +0200)
committerSebastian Dröge <sebastian.droege@collabora.co.uk>
Tue, 1 Sep 2009 05:28:43 +0000 (07:28 +0200)
Fixes bug #593719.

gst/gstiterator.c

index bdf5d5e..ad5d708 100644 (file)
@@ -724,7 +724,7 @@ gst_iterator_new_single (GType type, gpointer object, GstCopyFunction copy,
 
   result = (GstSingleObjectIterator *)
       gst_iterator_new (sizeof (GstSingleObjectIterator),
-      G_TYPE_FROM_INSTANCE (object), NULL, &_single_object_dummy_cookie,
+      type, NULL, &_single_object_dummy_cookie,
       (GstIteratorNextFunction) gst_single_object_iterator_iterator_next, NULL,
       (GstIteratorResyncFunction) gst_single_object_iterator_resync,
       (GstIteratorFreeFunction) gst_single_object_iterator_free);