Fix GLIB CRITICAL ** GStreamer - Could not convert static caps

"Marc-André Lureau" <[email protected]>
Newsgroups gmane.linux.bluez.devel
Message-ID <[email protected]>
Hi there,

patch attached.

   fix GStreamer critical "Could not convert static caps":
     - remove some trailing ';'
     - stringify attributes value in caps (cosmetic)


-- 
Marc-André Lureau

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

_______________________________________________
Bluez-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-devel
0001-Fix-GStreamer-critical-Could-not-convert-static-cap.patch (text/x-diff, 3.5 KB)
From a644548af176f7a52e4c99d350cb6f88a279392b Mon Sep 17 00:00:00 2001
From: Marc-Andre Lureau <[email protected]>
Date: Wed, 20 Feb 2008 11:37:00 +0200
Subject: [PATCH] Fix GStreamer critical "Could not convert static caps".

fix GStreamer critical "Could not convert static caps":
 - remove some trailing ';'
 - stringify attributes value in caps
---
 audio/gsta2dpsink.c  |    6 +++---
 audio/gstrtpsbcpay.c |    6 +++---
 audio/gstsbcenc.c    |    4 ++--
 audio/gstsbcparse.c  |    4 ++--
 4 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/audio/gsta2dpsink.c b/audio/gsta2dpsink.c
index 0b61e82..d25cbde 100644
--- a/audio/gsta2dpsink.c
+++ b/audio/gsta2dpsink.c
@@ -57,13 +57,13 @@ static GstStaticPadTemplate gst_a2dp_sink_factory =
 			GST_STATIC_CAPS("audio/x-sbc, "
 				"rate = (int) { 16000, 32000, 44100, 48000 }, "
 				"channels = (int) [ 1, 2 ], "
-				"mode = (string) { mono, dual, stereo, joint }, "
+				"mode = (string) { \"mono\", \"dual\", \"stereo\", \"joint\" }, "
 				"blocks = (int) { 4, 8, 12, 16 }, "
 				"subbands = (int) { 4, 8 }, "
-				"allocation = (string) { snr, loudness }, "
+				"allocation = (string) { \"snr\", \"loudness\" }, "
 				"bitpool = (int) [ 2, "
 				TEMPLATE_MAX_BITPOOL_STR " ]; "
-				"audio/mpeg;"
+				"audio/mpeg"
 				));
 
 static gboolean gst_a2dp_sink_handle_event(GstPad *pad, GstEvent *event);
diff --git a/audio/gstrtpsbcpay.c b/audio/gstrtpsbcpay.c
index 70f5bef..39cf197 100644
--- a/audio/gstrtpsbcpay.c
+++ b/audio/gstrtpsbcpay.c
@@ -80,11 +80,11 @@ static GstStaticPadTemplate gst_rtp_sbc_pay_sink_factory =
 		GST_STATIC_CAPS("audio/x-sbc, "
 				"rate = (int) { 16000, 32000, 44100, 48000 }, "
 				"channels = (int) [ 1, 2 ], "
-				"mode = (string) { mono, dual, stereo, joint }, "
+				"mode = (string) { \"mono\", \"dual\", \"stereo\", \"joint\" }, "
 				"blocks = (int) { 4, 8, 12, 16 }, "
 				"subbands = (int) { 4, 8 }, "
-				"allocation = (string) { snr, loudness },"
-				"bitpool = (int) [ 2, 64 ]; ")
+				"allocation = (string) { \"snr\", \"loudness\" }, "
+				"bitpool = (int) [ 2, 64 ]")
 	);
 
 static GstStaticPadTemplate gst_rtp_sbc_pay_src_factory =
diff --git a/audio/gstsbcenc.c b/audio/gstsbcenc.c
index 03423ec..65e3da5 100644
--- a/audio/gstsbcenc.c
+++ b/audio/gstsbcenc.c
@@ -157,10 +157,10 @@ static GstStaticPadTemplate sbc_enc_src_factory =
 		GST_STATIC_CAPS("audio/x-sbc, "
 				"rate = (int) { 16000, 32000, 44100, 48000 }, "
 				"channels = (int) [ 1, 2 ], "
-				"mode = (string) { mono, dual, stereo, joint }, "
+				"mode = (string) { \"mono\", \"dual\", \"stereo\", \"joint\" }, "
 				"blocks = (int) { 4, 8, 12, 16 }, "
 				"subbands = (int) { 4, 8 }, "
-				"allocation = (string) { snr, loudness },"
+				"allocation = (string) { \"snr\", \"loudness\" }, "
 				"bitpool = (int) [ " SBC_ENC_BITPOOL_MIN_STR
 				", " SBC_ENC_BITPOOL_MAX_STR " ]"));
 
diff --git a/audio/gstsbcparse.c b/audio/gstsbcparse.c
index 7b30dd2..4521c56 100644
--- a/audio/gstsbcparse.c
+++ b/audio/gstsbcparse.c
@@ -51,10 +51,10 @@ static GstStaticPadTemplate sbc_parse_src_factory =
 		GST_STATIC_CAPS("audio/x-sbc, "
 				"rate = (int) { 16000, 32000, 44100, 48000 }, "
 				"channels = (int) [ 1, 2 ], "
-				"mode = (string) { mono, dual, stereo, joint }, "
+				"mode = (string) { \"mono\", \"dual\", \"stereo\", \"joint\" }, "
 				"blocks = (int) { 4, 8, 12, 16 }, "
 				"subbands = (int) { 4, 8 }, "
-				"allocation = (string) { snr, loudness },"
+				"allocation = (string) { \"snr\", \"loudness\" },"
 				"bitpool = (int) [ 2, 64 ],"
 				"parsed = (boolean) true"));
 
-- 
1.5.4.1.34.g94bf
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.