X-Git-Url: http://git.eversberg.eu/gitweb.cgi?p=lcr.git;a=blobdiff_plain;f=interface.c;h=89aa5827cd3bd4eda033723d7121f620c8087431;hp=60e058f99617b231a2f0b96629381506ea15c46a;hb=74a7fe54a81bb7e996ea45203bbc8cc0ff6b8dda;hpb=d928442c511fbe7a0d0d0f9e701412b9b494457c;ds=sidebyside diff --git a/interface.c b/interface.c index 60e058f..89aa582 100644 --- a/interface.c +++ b/interface.c @@ -1072,16 +1072,25 @@ static int inter_remote(struct interface *interface, char *filename, int line, c ifport->remote = 1; SCPY(ifport->remote_app, value); - return(0); } - static int inter_shutdown(struct interface *interface, char *filename, int line, char *parameter, char *value) { interface->shutdown = 1; return(0); } +static int inter_bridge(struct interface *interface, char *filename, int line, char *parameter, char *value) +{ + if (!value || !value[0]) { + SPRINT(interface_error, "Error in %s (line %d): Missing destination interface name.\n", filename, line); + return(-1); + } + interface->app = EAPP_TYPE_BRIDGE; + SCPY(interface->bridge_if, value); + + return(0); +} /* @@ -1230,6 +1239,10 @@ struct interface_param interface_param[] = { "Prevents sending notify messages to this interface. A call placed on hold will\n" "Not affect the remote end (phone or telcom switch).\n" "This parameter must follow a 'port' parameter."}, + {"bridge", &inter_bridge, "", + "Define bridge application for this interface. All calls received on this\n" + "interface will be directly bridged to the given destination interface.\n" + "There will be no PBX application, nor routing."}, #ifdef WITH_SS5 {"ccitt5", &inter_ss5, "[ [feature ...]]",