aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuiz Augusto von Dentz <luiz.dentz-von@nokia.com>2010-09-13 15:40:11 +0300
committerJohan Hedberg <johan.hedberg@nokia.com>2010-09-13 16:20:35 +0300
commitdbf642ce320cc7241d78823dc4143a1fe71c35a7 (patch)
tree758dde80618e95bf32be3db7da069e8ec9401101
parentf57cb78379bf698472d2077daca5b80ca71261f7 (diff)
downloadbluez-dbf642ce320cc7241d78823dc4143a1fe71c35a7.tar.gz
bluez-dbf642ce320cc7241d78823dc4143a1fe71c35a7.tar.xz
bluez-dbf642ce320cc7241d78823dc4143a1fe71c35a7.zip
Fix crash on gstreamer plugin if device doesn't support sbc
-rw-r--r--audio/gstavdtpsink.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/audio/gstavdtpsink.c b/audio/gstavdtpsink.c
index f0e5b76a..b8c8832a 100644
--- a/audio/gstavdtpsink.c
+++ b/audio/gstavdtpsink.c
@@ -448,6 +448,9 @@ static GstStructure *gst_avdtp_sink_parse_sbc_caps(
GValue *list;
gboolean mono, stereo;
+ if (sbc == NULL)
+ return NULL;
+
structure = gst_structure_empty_new("audio/x-sbc");
value = g_value_init(g_new0(GValue, 1), G_TYPE_STRING);