T.140: Fix format ref and memory leaks.

* channel.c:ast_sendtext(): Fix T.140 SendText memory leak.

* format_compatibility.c: T.140 RED and T.140 were swapped.

* res_rtp_asterisk.c:rtp_red_init(): Fix ast_format_t140_red ref leak.

* res_rtp_asterisk.c:rtp_red_init(): Fix data race after starting periodic
scheduled red_write().

* res_rtp_asterisk.c: Some other minor misc tweaks.

Change-Id: Ifa27a2e0f8a966b1cf628607c86fc4374b0b88cb
This commit is contained in:
Richard Mudgett
2017-01-10 17:39:02 -06:00
parent b21ab3f1cd
commit 20aed30d9a
3 changed files with 16 additions and 14 deletions

View File

@@ -262,10 +262,10 @@ struct ast_format *ast_format_compatibility_bitfield2format(uint64_t bitfield)
/*! T.140 RED Text format RFC 4103 */
case AST_FORMAT_T140_RED:
return ast_format_t140;
return ast_format_t140_red;
/*! T.140 Text format - ITU T.140, RFC 4103 */
case AST_FORMAT_T140:
return ast_format_t140_red;
return ast_format_t140;
}
return NULL;
}