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 701323 - input-selector: crash when requesting "active" property of pad with no selector
input-selector: crash when requesting "active" property of pad with no selector
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal normal
: 1.1.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-05-31 01:39 UTC by Brendan Long
Modified: 2013-06-04 15:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Return FALSE for "active" property on input-selector pad if the input selector is deleted (1.14 KB, patch)
2013-05-31 01:39 UTC, Brendan Long
committed Details | Review
Slightly more succinct patch (1.08 KB, patch)
2013-05-31 05:01 UTC, Brendan Long
none Details | Review

Description Brendan Long 2013-05-31 01:39:00 UTC
Created attachment 245696 [details] [review]
Return FALSE for "active" property on input-selector pad if the input selector is deleted

It's possible to have a reference to an input-selectors pads after it is deleted. If you do a `g_object_get(pad, "active", &active; NULL)`, it will segfault because the input selector (`sel`) is NULL.

This patch returns FALSE if there's no selector.
Comment 1 Brendan Long 2013-05-31 05:01:36 UTC
Created attachment 245701 [details] [review]
Slightly more succinct patch

I can't decide if this one is better or not. I like how it's less repetitive, but I don't like how it checks `sel` twice. Up to you..
Comment 2 Sebastian Dröge (slomo) 2013-06-04 15:46:56 UTC
commit 76f0e18f92cfd3444303ec0b025653f3d997b7e0
Author: Brendan Long <self@brendanlong.com>
Date:   Thu May 30 22:57:49 2013 -0600

    input-selector: return FALSE for "active" property if selector is NULL
    
    https://bugzilla.gnome.org/show_bug.cgi?id=701323