From fb6e219eda69fe19fdd16457570dd51d07099320 Mon Sep 17 00:00:00 2001 From: Andreas Eversberg Date: Sun, 15 Feb 2009 09:04:14 +0100 Subject: chan_lcr hopefully now compiles against SVN version of asterisk. Added limitation option for maximum dialed digits. If dial string exceeds that limit, overlap-dialing is used to complete dial string. Siemens EWSD (APS V16) only allows 20 digits at a time. modified: README modified: chan_lcr.c modified: default/interface.conf modified: dss1.cpp modified: dss1.h modified: ie.cpp modified: interface.c modified: interface.h --- interface.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'interface.c') diff --git a/interface.c b/interface.c index 5549654..1e4bc66 100644 --- a/interface.c +++ b/interface.c @@ -898,6 +898,23 @@ static int inter_filter(struct interface *interface, char *filename, int line, c } return(0); } +static int inter_dialmax(struct interface *interface, char *filename, int line, char *parameter, char *value) +{ + struct interface_port *ifport; + + /* port in chain ? */ + if (!interface->ifport) + { + SPRINT(interface_error, "Error in %s (line %d): parameter '%s' expects previous 'port' definition.\n", filename, line, parameter); + return(-1); + } + /* goto end of chain */ + ifport = interface->ifport; + while(ifport->next) + ifport = ifport->next; + ifport->dialmax = atoi(value); + return(0); +} /* @@ -1008,6 +1025,9 @@ struct interface_param interface_param[] = { "pipeline - Sets echo cancelation pipeline.\n" "blowfish - Adds encryption. Key must be 4-56 bytes (8-112 hex characters."}, + {"dialmax", &inter_dialmax, "", + "Limits the number of digits in setup/information message."}, + {NULL, NULL, NULL, NULL} }; -- cgit v1.2.3-55-g7522