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 750439 - playbin using fdsrc source hangs for with empty input
playbin using fdsrc source hangs for with empty input
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
Other Linux
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Reported: 2015-06-05 06:31 UTC by James Henstridge
Modified: 2015-06-05 08:07 UTC
See Also:
GNOME target: ---
GNOME version: ---

Description James Henstridge 2015-06-05 06:31:40 UTC
Playbin appears to hang when using an fdsrc that is at eof.  I can reproduce this using the standard utilities like so:

    $ touch empty
    $ gst-launch-1.0 playbin uri=fd://3 3< empty 
    Setting pipeline to PAUSED ...
    Pipeline is PREROLLING ...

At this point, it hangs until I kill the process.  Instead, I would expect the playbin to behave in the same way as if I was using filesrc with the same empty file:

    $ gst-launch-1.0 playbin uri=file://$PWD/empty
    Setting pipeline to PAUSED ...
    Pipeline is PREROLLING ...
    ERROR: from element /GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstTypeFindElement:typefind: Stream contains no data.
    Additional debug info:
    gsttypefindelement.c(1055): gst_type_find_element_loop (): /GstPlayBin:playbin0/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstTypeFindElement:typefind:
    Can't typefind empty stream
    ERROR: pipeline doesn't want to preroll.
    Setting pipeline to NULL ...
    Freeing pipeline ...

I tested this on an Ubuntu 15.04 amd64 box, which has the 1.4.5-1 GStreamer packages installed.
Comment 1 Sebastian Dröge (slomo) 2015-06-05 07:50:34 UTC
Running this in a debugger shows that not even any of the fdsrc or other pipeline threads are still running:

Thread 2 (Thread 0x7ffff4a3b700 (LWP 502))

  • #0 syscall
    at ../sysdeps/unix/sysv/linux/x86_64/syscall.S line 38
  • #1 g_cond_wait
    at /build/glib2.0-NiYzoW/glib2.0-2.44.1/./glib/gthread-posix.c line 1395
  • #2 gst_task_func
    at gsttask.c line 316
  • #3 g_thread_pool_thread_proxy
    at /build/glib2.0-NiYzoW/glib2.0-2.44.1/./glib/gthreadpool.c line 307
  • #4 g_thread_proxy
    at /build/glib2.0-NiYzoW/glib2.0-2.44.1/./glib/gthread.c line 764
  • #5 start_thread
    at pthread_create.c line 309
  • #6 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 111

Comment 2 Sebastian Dröge (slomo) 2015-06-05 08:07:04 UTC
Simpler testcase:
gst-launch-1.0 fdsrc fd=3 ! typefind ! fakesink 3< /dev/null

commit 91f537edf2946cbb5085782693b6c5111333db5f
Author: Sebastian Dröge <>
Date:   Fri Jun 5 10:02:04 2015 +0200

    typefind: Post an error if we can't typefind the data until EOS