Set the context properly for a given peer

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@2336 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Mark Spencer
2004-03-04 23:43:58 +00:00
parent 595049117c
commit b4ea3725da

View File

@@ -2122,6 +2122,8 @@ static int iax2_call(struct ast_channel *c, char *dest, int timeout)
if (!secret && strlen(storedsecret))
secret = storedsecret;
ast_mutex_lock(&iaxsl[callno]);
if (strlen(c->context))
strncpy(iaxs[callno]->context, c->context, sizeof(iaxs[callno]->context));
if (secret) {
if (secret[0] == '[') {
/* This is an RSA key, not a normal secret */