a bunch of conversion to ast_channel_*lock (issue #7058)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@23355 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant
2006-04-29 14:50:18 +00:00
parent 54d6194340
commit 8085f4e14b
10 changed files with 67 additions and 67 deletions

View File

@@ -216,7 +216,7 @@ static u_char *ast_var_channels_table(struct variable *vp, oid *name, size_t *le
for (chan = ast_channel_walk_locked(NULL);
chan && i;
chan = ast_channel_walk_locked(chan), i--)
ast_mutex_unlock(&chan->lock);
ast_channel_unlock(chan);
if (chan == NULL)
return NULL;
*var_len = sizeof(long_ret);
@@ -513,7 +513,7 @@ static u_char *ast_var_channels_table(struct variable *vp, oid *name, size_t *le
ret = NULL;
break;
}
ast_mutex_unlock(&chan->lock);
ast_channel_unlock(chan);
return ret;
}
@@ -583,7 +583,7 @@ static u_char *ast_var_channel_types_table(struct variable *vp, oid *name, size_
case ASTCHANTYPECHANNELS:
long_ret = 0;
for (chan = ast_channel_walk_locked(NULL); chan; chan = ast_channel_walk_locked(chan)) {
ast_mutex_unlock(&chan->lock);
ast_channel_unlock(chan);
if (chan->tech == tech)
long_ret++;
}