diff options
author | crichter <crichter@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-10-10 13:34:33 +0000 |
---|---|---|
committer | crichter <crichter@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-10-10 13:34:33 +0000 |
commit | 54b6e50502ff33fd6c68d2ae03b2af0f5eedaa9e (patch) | |
tree | ddf376e912f05655b5d6bec40ae27bc80ecf8c51 | |
parent | 04cd0490fb3d90fc5128b3d1ffe761066a503391 (diff) |
(re)added support of dynamical enabling hdlc on bchannels
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@44785 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | channels/chan_misdn.c | 5 | ||||
-rw-r--r-- | channels/misdn/isdn_lib.c | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/channels/chan_misdn.c b/channels/chan_misdn.c index b6280ce0b..2fddfe3d5 100644 --- a/channels/chan_misdn.c +++ b/channels/chan_misdn.c @@ -4463,7 +4463,10 @@ static int misdn_set_opt_exec(struct ast_channel *chan, void *data) if (strlen(tok) > 1 && tok[1]=='1') { chan_misdn_log(1, ch->bc->port, "SETOPT: HDLC \n"); - ch->bc->hdlc=1; + if (!ch->bc->hdlc) { + ch->bc->hdlc=1; + misdn_lib_setup_bc(ch->bc); + } } ch->bc->capability=INFO_CAPABILITY_DIGITAL_UNRESTRICTED; break; diff --git a/channels/misdn/isdn_lib.c b/channels/misdn/isdn_lib.c index c0fdf31d8..ce25791a4 100644 --- a/channels/misdn/isdn_lib.c +++ b/channels/misdn/isdn_lib.c @@ -882,6 +882,7 @@ static int create_process (int midev, struct misdn_bchannel *bc) { void misdn_lib_setup_bc(struct misdn_bchannel *bc) { + clean_up_bc(bc); setup_bc(bc); } |