automerge commit

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2-netsec@59007 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Automerge Script
2007-03-16 16:22:58 +00:00
parent 70c96b9bc6
commit 28d60b864c
8 changed files with 104 additions and 48 deletions

View File

@@ -349,9 +349,12 @@ int misdn_cfg_is_port_valid (int port)
int misdn_cfg_is_group_method (char *group, enum misdn_cfg_method meth)
{
int i, re = 0;
char *method = NULL;
char *method ;
misdn_cfg_lock();
method = port_cfg[0][map[MISDN_CFG_METHOD]].str;
for (i = 1; i <= max_ports; i++) {
if (port_cfg[i] && port_cfg[i][map[MISDN_CFG_GROUPNAME]].str) {
if (!strcasecmp(port_cfg[i][map[MISDN_CFG_GROUPNAME]].str, group))
@@ -359,12 +362,15 @@ int misdn_cfg_is_group_method (char *group, enum misdn_cfg_method meth)
port_cfg[i][map[MISDN_CFG_METHOD]].str : port_cfg[0][map[MISDN_CFG_METHOD]].str);
}
}
if (method) {
switch (meth) {
case METHOD_STANDARD: re = !strcasecmp(method, "standard");
break;
case METHOD_ROUND_ROBIN: re = !strcasecmp(method, "round_robin");
break;
case METHOD_STANDARD_DEC: re = !strcasecmp(method, "standard_dec");
break;
}
}
misdn_cfg_unlock();