char string[1024], *p = string, *opt, *key;
int gain, i, newmode = 0;
+ if (!data[0])
+ return; // no opts
+
strncpy(string, data, sizeof(string)-1);
string[sizeof(string)-1] = '\0';
CDEBUG(call, call->ast, "Join bchannel, because call is already bridged.\n");
bchannel_join(bchannel, call->bridge_id);
}
+ /* create only, if call exists, othewhise it bchannel is freed below... */
+ if (bchannel_create(bchannel, ((call->transparent)?1:0) + ((call->hdlc)?2:0)))
+ bchannel_activate(bchannel, 1);
}
- if (bchannel_create(bchannel, ((call->transparent)?1:0) + ((call->hdlc)?2:0)))
- bchannel_activate(bchannel, 1);
/* acknowledge */
newparam.bchannel.type = BCHANNEL_ASSIGN_ACK;
newparam.bchannel.handle = param->bchannel.handle;
return 0;
}
-static int lcr_digit(struct ast_channel *ast, char digit)
+static int lcr_digit_begin(struct ast_channel *ast, char digit)
+{
+ printf("DIGT BEGIN %c\n", digit);
+ return (0);
+}
+
+static int lcr_digit_end(struct ast_channel *ast, char digit, unsigned int duration)
{
struct chan_call *call;
union parameter newparam;
.type="LCR",
.description="Channel driver for connecting to Linux-Call-Router",
.requester=lcr_request,
- .send_digit_begin=lcr_digit,
+ .send_digit_begin=lcr_digit_begin,
+ .send_digit_end=lcr_digit_end,
.call=lcr_call,
.bridge=lcr_bridge,
.hangup=lcr_hangup,