aboutsummaryrefslogtreecommitdiffstats
path: root/channels/chan_h323.c
diff options
context:
space:
mode:
authorpcadach <pcadach@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-18 06:59:22 +0000
committerpcadach <pcadach@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-18 06:59:22 +0000
commit1661f462680113db414aa4b5d3fcf4118e0f9e7b (patch)
treeb61facd1905f6dc6b1ed65332d42377f59a39be3 /channels/chan_h323.c
parent69a268902eff1dece963c98e603741ed82d81b2b (diff)
Update ast_append_ha() usage
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@51221 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_h323.c')
-rw-r--r--channels/chan_h323.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/channels/chan_h323.c b/channels/chan_h323.c
index 096e8ddbc..ef099eb52 100644
--- a/channels/chan_h323.c
+++ b/channels/chan_h323.c
@@ -1425,7 +1425,11 @@ static struct oh323_user *build_user(char *name, struct ast_variable *v, struct
}
} else if (!strcasecmp(v->name, "permit") ||
!strcasecmp(v->name, "deny")) {
- user->ha = ast_append_ha(v->name, v->value, user->ha, NULL);
+ int ha_error = 0;
+
+ user->ha = ast_append_ha(v->name, v->value, user->ha, &ha_error);
+ if (ha_error)
+ ast_log(LOG_ERROR, "Bad ACL entry in configuration line %d : %s\n", v->lineno, v->value);
}
}
if (!user->options.dtmfmode)
@@ -1529,7 +1533,11 @@ static struct oh323_peer *build_peer(const char *name, struct ast_variable *v, s
peer->addr.sin_port = htons(atoi(v->value));
} else if (!strcasecmp(v->name, "permit") ||
!strcasecmp(v->name, "deny")) {
- peer->ha = ast_append_ha(v->name, v->value, peer->ha);
+ int ha_error = 0;
+
+ peer->ha = ast_append_ha(v->name, v->value, peer->ha, &ha_error);
+ if (ha_error)
+ ast_log(LOG_ERROR, "Bad ACL entry in configuration line %d : %s\n", v->lineno, v->value);
} else if (!strcasecmp(v->name, "mailbox")) {
ast_copy_string(peer->mailbox, v->value, sizeof(peer->mailbox));
}