Opaquify channel stringfields

Continue channel opaque-ification by wrapping all of the stringfields.
Eventually, we will restrict what can actually set these variables, but
the purpose for now is to hide the implementation and keep people from
adding code that directly accesses the channel structure. Semantic
changes will follow afterward.

Review: https://reviewboard.asterisk.org/r/1661/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@352348 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Terry Wilson
2012-01-24 20:12:09 +00:00
parent 2144ba5df2
commit 99cae5b750
74 changed files with 858 additions and 801 deletions

View File

@@ -439,7 +439,7 @@ static struct ast_channel * analog_new_ast_channel(struct analog_pvt *p, int sta
c = p->calls->new_ast_channel(p->chan_pvt, state, startpbx, sub, requestor);
if (c) {
ast_string_field_set(c, call_forward, p->call_forward);
ast_channel_call_forward_set(c, p->call_forward);
}
p->subs[sub].owner = c;
if (!p->owner) {
@@ -705,7 +705,7 @@ static int analog_attempt_transfer(struct analog_pvt *p, int inthreeway)
(owner_real->_state == AST_STATE_RINGING
|| owner_3way->_state == AST_STATE_RINGING)
? AST_CEL_BLINDTRANSFER : AST_CEL_ATTENDEDTRANSFER,
NULL, owner_3way->linkedid, NULL);
NULL, ast_channel_linkedid(owner_3way), NULL);
/*
* The three-way party we're about to transfer is on hold if he
@@ -731,7 +731,7 @@ static int analog_attempt_transfer(struct analog_pvt *p, int inthreeway)
(owner_real->_state == AST_STATE_RINGING
|| owner_3way->_state == AST_STATE_RINGING)
? AST_CEL_BLINDTRANSFER : AST_CEL_ATTENDEDTRANSFER,
NULL, owner_3way->linkedid, NULL);
NULL, ast_channel_linkedid(owner_3way), NULL);
/*
* The three-way party we're about to transfer is on hold if he
@@ -2078,7 +2078,7 @@ static void *__analog_ss_thread(void *data)
} else {
sleep(1);
}
res = ast_streamfile(chan, "ss-noservice", chan->language);
res = ast_streamfile(chan, "ss-noservice", ast_channel_language(chan));
if (res >= 0) {
ast_waitstream(chan, "");
}
@@ -2233,7 +2233,7 @@ static void *__analog_ss_thread(void *data)
} else if (p->callreturn && !strcmp(exten, "*69")) {
res = 0;
if (!ast_strlen_zero(p->lastcid_num)) {
res = ast_say_digit_str(chan, p->lastcid_num, "", chan->language);
res = ast_say_digit_str(chan, p->lastcid_num, "", ast_channel_language(chan));
}
if (!res) {
res = analog_play_tone(p, idx, ANALOG_TONE_DIALRECALL);