[asterisk-commits] wedhorn: branch group/media_formats-reviewed-trunk r418867 - /team/group/medi...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jul 17 15:31:55 CDT 2014


Author: wedhorn
Date: Thu Jul 17 15:31:51 2014
New Revision: 418867

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=418867
Log:
Skinny: minor fixes for new media formats.

Return ast_format_none rather than NULL from function codec_skinny2ast. Allocate space
for a codec buffer that was causing a segfault if debug audio was on during device
registration. Also adds a debug message for when rtp started.

Modified:
    team/group/media_formats-reviewed-trunk/channels/chan_skinny.c

Modified: team/group/media_formats-reviewed-trunk/channels/chan_skinny.c
URL: http://svnview.digium.com/svn/asterisk/team/group/media_formats-reviewed-trunk/channels/chan_skinny.c?view=diff&rev=418867&r1=418866&r2=418867
==============================================================================
--- team/group/media_formats-reviewed-trunk/channels/chan_skinny.c (original)
+++ team/group/media_formats-reviewed-trunk/channels/chan_skinny.c Thu Jul 17 15:31:51 2014
@@ -2118,7 +2118,7 @@
 	case SKINNY_CODEC_H263:
 		return ast_format_h263;
 	default:
-		return NULL;
+		return ast_format_none;
 	}
 }
 
@@ -4749,7 +4749,7 @@
 	struct ast_sockaddr bindaddr_tmp;
 
 	skinny_locksub(sub);
-	/* Allocate the RTP */
+	SKINNY_DEBUG(DEBUG_AUDIO, 3, "Sub %u - Starting RTP\n", sub->callid);
 	ast_sockaddr_from_sin(&bindaddr_tmp, &bindaddr);
 	sub->rtp = ast_rtp_instance_new("asterisk", sched, &bindaddr_tmp, NULL);
 	if (hasvideo)
@@ -6645,7 +6645,7 @@
 	struct skinny_line *l;
 	uint32_t count = 0;
 	struct ast_format_cap *codecs = ast_format_cap_alloc(AST_FORMAT_CAP_FLAG_DEFAULT);
-	struct ast_str *codec_buf;
+	struct ast_str *codec_buf = ast_str_alloca(64);
 	int i;
 
 	if (!codecs) {




More information about the asterisk-commits mailing list