touch-packages team mailing list archive
-
touch-packages team
-
Mailing list archive
-
Message #130966
[Bug 1529445] Re: Several memory/file descriptor leaks in gstreamer 1.6.0
Status changed to 'Confirmed' because the bug affects multiple users.
** Changed in: gstreamer1.0 (Ubuntu)
Status: New => Confirmed
--
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to gst-plugins-base1.0 in
Ubuntu.
https://bugs.launchpad.net/bugs/1529445
Title:
Several memory/file descriptor leaks in gstreamer 1.6.0
Status in gst-plugins-base1.0 package in Ubuntu:
Confirmed
Status in gstreamer1.0 package in Ubuntu:
Confirmed
Bug description:
Ubuntu 15.10 includes gstreamer 1.6.0. There were several important
leak fixes in 1.6.1, some of which also meant holding references to
file descriptors around, which can result in crashes once the fd limit
is hit.
Upstream bugs:
https://bugzilla.gnome.org/show_bug.cgi?id=755867
https://bugzilla.gnome.org/show_bug.cgi?id=756552
https://bugzilla.gnome.org/show_bug.cgi?id=756611
All of these were fixed in 1.6.1
What motivated me to investigate this bug is a 'random' crash in
pidgin after several hours of leaking file descriptors, which looks
exactly like bug #1479715 but happened even after applying that patch.
Turns out that it wasn't pidgin holding the references that kept those
file descriptors open, but it was gstreamer itself.
I'd fill the whole SRU template here but i'm afraid there are too many
patches that need to be applied to fix these bugs properly (some of
them in gst-plugins-base, some of them in libgstreamer, and I don't
know exactly which ones are needed) and anything less than updating to
1.6.1 or 1.6.2 would be wrong, IMO. The whole 1.6.x branch is bugfixes
only.
[Test Case]
* Download https://bugzilla.gnome.org/attachment.cgi?id=313241 to
playbin-leak.c
* Optionally change the "a.ogg" uri to a valid path to a sound in the
local system (maybe "file:///usr/share/sounds/alsa/Noise.wav"). Some
leaks and warnings appear anyway even without changing this.
* Build with:
gcc -Wall $(pkg-config --cflags gstreamer-1.0 gtk+-3.0 glib-2.0)
playbin-leak.c $(pkg-config --libs gstreamer-1.0 gtk+-3.0 glib-2.0)
* Run as:
GOBJECT_DEBUG=instance-count GTK_DEBUG=interactive ./a.out
* Let it run, see warnings after some iterations, watch it leak.
Alternatively, how i've been testing this so far, which roughly
imitates the pidgin crash (but probably only applies to a subset of
the leaks)
* Get a ubuntu 15.10 VM without sound card (so that pulseaudio fails
to play sounds)
* Do this:
cd /usr/share/sounds/alsa
valgrind --track-fds=yes gst-play-1.0 --audiosink=pulsesink Noise.wav Noise.wav Noise.wav
* File descriptors open at exit should be 4, not 10 (it leaks two for
each time it plays)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gst-plugins-base1.0/+bug/1529445/+subscriptions
References