summaryrefslogtreecommitdiff
path: root/res/res_features.c
diff options
context:
space:
mode:
authorKevin P. Fleming <kpfleming@digium.com>2006-02-01 23:05:28 +0000
committerKevin P. Fleming <kpfleming@digium.com>2006-02-01 23:05:28 +0000
commita16ae226b685a8c434ec4f7eecf4ee8864fde4c7 (patch)
tree86a6664b5cba70b924fdd1cef2ecbf93226e7d58 /res/res_features.c
parentf246b9fc64ea8843f419947045574edb2681f9a2 (diff)
use string fields for some stuff in ast_channel
const-ify some more APIs remove 'type' field from ast_channel, in favor of the one in the channel's tech structure allow string field module users to specify the 'chunk size' for pool allocations update chan_alsa to be compatible with recent const-ification patches git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@9060 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_features.c')
-rw-r--r--res/res_features.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/res/res_features.c b/res/res_features.c
index c705b2310..d39212131 100644
--- a/res/res_features.c
+++ b/res/res_features.c
@@ -174,7 +174,7 @@ static void check_goto_on_transfer(struct ast_channel *chan)
for (x = goto_on_transfer; x && *x; x++)
if (*x == '^')
*x = '|';
- strcpy(xferchan->name, chan->name);
+ ast_string_field_set(xferchan, name, chan->name);
/* Make formats okay */
xferchan->readformat = chan->readformat;
xferchan->writeformat = chan->writeformat;
@@ -201,9 +201,9 @@ static void *ast_bridge_call_thread(void *data)
struct ast_bridge_thread_obj *tobj = data;
tobj->chan->appl = "Transferred Call";
- tobj->chan->data = tobj->peer->name;
+ tobj->chan->data = (char *) tobj->peer->name;
tobj->peer->appl = "Transferred Call";
- tobj->peer->data = tobj->chan->name;
+ tobj->peer->data = (char *) tobj->chan->name;
if (tobj->chan->cdr) {
ast_cdr_reset(tobj->chan->cdr, NULL);
ast_cdr_setdestchan(tobj->chan->cdr, tobj->peer->name);
@@ -385,7 +385,7 @@ int ast_masq_park_call(struct ast_channel *rchan, struct ast_channel *peer, int
/* Make a new, fake channel that we'll use to masquerade in the real one */
if ((chan = ast_channel_alloc(0))) {
/* Let us keep track of the channel name */
- snprintf(chan->name, sizeof (chan->name), "Parked/%s",rchan->name);
+ ast_string_field_build(chan, name, "Parked/%s",rchan->name);
/* Make formats okay */
chan->readformat = rchan->readformat;
@@ -758,7 +758,7 @@ static int builtin_atxfer(struct ast_channel *chan, struct ast_channel *peer, st
}
if ((xferchan = ast_channel_alloc(0))) {
- snprintf(xferchan->name, sizeof (xferchan->name), "Transfered/%s",transferee->name);
+ ast_string_field_build(xferchan, name, "Transfered/%s", transferee->name);
/* Make formats okay */
xferchan->readformat = transferee->readformat;
xferchan->writeformat = transferee->writeformat;
@@ -1280,7 +1280,7 @@ int ast_bridge_call(struct ast_channel *chan,struct ast_channel *peer,struct ast
if (ast_answer(chan))
return -1;
peer->appl = "Bridged Call";
- peer->data = chan->name;
+ peer->data = (char *) chan->name;
/* copy the userfield from the B-leg to A-leg if applicable */
if (chan->cdr && peer->cdr && !ast_strlen_zero(peer->cdr->userfield)) {