summaryrefslogtreecommitdiff
path: root/channels/chan_mgcp.c
diff options
context:
space:
mode:
authorAlexander Traud <pabstraud@compuserve.com>2015-11-09 10:01:41 +0100
committerAlexander Traud <pabstraud@compuserve.com>2015-11-09 16:58:52 +0100
commitcf79b627789e2c6434419b71508a296c9ee90539 (patch)
treede7a9f429d1a77bec41957e661d17bd96d8ac06f /channels/chan_mgcp.c
parentf12ebe35848c2ce82e53b332742e83b2b5875502 (diff)
ast_format_cap_get_names: To display all formats, the buffer was increased.
ASTERISK-25533 #close Change-Id: Ie1a9d1a6511b3f1a56b93d04475fbf8a4e40010a
Diffstat (limited to 'channels/chan_mgcp.c')
-rw-r--r--channels/chan_mgcp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/channels/chan_mgcp.c b/channels/chan_mgcp.c
index 0210e8ab2..8714ddbbc 100644
--- a/channels/chan_mgcp.c
+++ b/channels/chan_mgcp.c
@@ -1253,7 +1253,7 @@ static int mgcp_write(struct ast_channel *ast, struct ast_frame *frame)
}
} else {
if (ast_format_cap_iscompatible_format(ast_channel_nativeformats(ast), frame->subclass.format) == AST_FORMAT_CMP_NOT_EQUAL) {
- struct ast_str *cap_buf = ast_str_alloca(64);
+ struct ast_str *cap_buf = ast_str_alloca(AST_FORMAT_CAP_NAMES_LEN);
ast_log(LOG_WARNING, "Asked to transmit frame type %s, while native formats is %s (read/write = %s/%s)\n",
ast_format_get_name(frame->subclass.format),
@@ -1986,9 +1986,9 @@ static int process_sdp(struct mgcp_subchannel *sub, struct mgcp_request *req)
int codec, codec_count=0;
int iterator;
struct mgcp_endpoint *p = sub->parent;
- struct ast_str *global_buf = ast_str_alloca(64);
- struct ast_str *peer_buf = ast_str_alloca(64);
- struct ast_str *pvt_buf = ast_str_alloca(64);
+ struct ast_str *global_buf = ast_str_alloca(AST_FORMAT_CAP_NAMES_LEN);
+ struct ast_str *peer_buf = ast_str_alloca(AST_FORMAT_CAP_NAMES_LEN);
+ struct ast_str *pvt_buf = ast_str_alloca(AST_FORMAT_CAP_NAMES_LEN);
/* Get codec and RTP info from SDP */
m = get_sdp(req, "m");
@@ -3971,7 +3971,7 @@ static struct ast_channel *mgcp_request(const char *type, struct ast_format_cap
char tmp[256];
if (!(ast_format_cap_iscompatible(cap, global_capability))) {
- struct ast_str *cap_buf = ast_str_alloca(64);
+ struct ast_str *cap_buf = ast_str_alloca(AST_FORMAT_CAP_NAMES_LEN);
ast_log(LOG_NOTICE, "Asked to get a channel of unsupported format '%s'\n",
ast_format_cap_get_names(cap, &cap_buf));
/*return NULL;*/