After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 693065 - pipeline: criticals when seeking on pipeline with NULL clock
pipeline: criticals when seeking on pipeline with NULL clock
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
Other Linux
: Normal normal
: 1.0.6
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Reported: 2013-02-02 19:18 UTC by Nate Bogdanowicz
Modified: 2013-02-05 13:44 UTC
See Also:
GNOME target: ---
GNOME version: ---

Null-check patch (1.19 KB, patch)
2013-02-02 20:15 UTC, Nate Bogdanowicz
committed Details | Review

Description Nate Bogdanowicz 2013-02-02 19:18:11 UTC
I first posted about this on the gstreamer-devel mailing list:

What follows is mostly a rehash of that post.

When I create a pipeline and tell it to gst_pipeline_use_clock(..., NULL) and later call a flushing seek, I get a "GStreamer-CRITICAL **: gst_object_ref: assertion `object != NULL' failed". Removing the _use_clock() call eliminates this problem. Using gdb, I can see that the problem comes when gst_pipeline_change_state() tries to gst_object_ref(cur_clock) in gstpipeline.c:422 (in gstreamer 0.10.36).

I've made a simple patch that inserts a null-check, which fixes the issue. I'll attach this shortly.

This problem also seems to exist in the 1.0 branch, judging by the source code.
Comment 1 Nate Bogdanowicz 2013-02-02 20:15:38 UTC
Created attachment 235074 [details] [review]
Null-check patch

This is a patch against the latest git commit.
Comment 2 Wim Taymans 2013-02-05 13:29:50 UTC
commit 25c64901096ce70dd63f055fc1243e53492334bc
Author: Nate Bogdanowicz <>
Date:   Sat Feb 2 11:55:52 2013 -0800

    gstpipeline: fix failed assertion caused by seeking pipeline with NULL clock
    Under certain GST_STATE_CHANGED_PAUSED_TO_PLAYING transitions, a pipeline with
    a NULL clock will fail an assertion due to an unchecked call to gst_object_ref().
    This is fixed by simply adding a check and only ref-ing if the clock is not NULL.