GNOME Bugzilla – Bug 689597
gst-rtsp-server: keep rtsp-media alive until bus watch is destroyed
Last modified: 2012-12-10 09:54:50 UTC
It is possible that the thread than handles bus messages in rtsp-media is interrupted while rtsp-media is being destroyed. This will cause segmentation faults and/or memory corruption when the bus message thread gets control again (if it access the media element). This is currently solved in gst-rtsp-server master branch by referencing media when the gsource is created and a GDestroyNotify function takes care of unreferencing media.
Created attachment 230631 [details] [review] ref/unref media in gsource creation/destruction
Created attachment 230632 [details] [review] ref/unref media in gsource creation/destruction Updated file name (to avoid confusion). It was missing first digit in bug number.
Author: Aleix Conchillo Flaque <aleix@oblong.com> 2012-12-04 10:32:46 Committer: Wim Taymans <wim.taymans@collabora.co.uk> 2012-12-10 10:51:40 Parent: 0f6d0c71990e5ac87ada503ba2ed9509400ba9cf (disable deprecation warnings) Branches: 0.10, remotes/origin/0.10 Follows: RELEASE-0.10.8 Precedes: keep rtsp-media alive until bus watch is destroyed * gst/rtsp-server/rtsp-media.c: media is now referenced by the GSource (bus message watch) and unreferenced when the GSource is destroyed (when media is unprepared). This avoids destroying media while bus message handle is being executed. https://bugzilla.gnome.org/show_bug.cgi?id=689597