]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 44785 via svnmerge from
authorChristian Richter <christian.richter@beronet.com>
Tue, 10 Oct 2006 13:50:26 +0000 (13:50 +0000)
committerChristian Richter <christian.richter@beronet.com>
Tue, 10 Oct 2006 13:50:26 +0000 (13:50 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r44785 | crichter | 2006-10-10 15:34:33 +0200 (Di, 10 Okt 2006) | 1 line

(re)added support of dynamical enabling hdlc on bchannels
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@44786 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_misdn.c
channels/misdn/isdn_lib.c

index 76b4165bc5bb3d8ddc1ee1c8f934abc7bb73c2ed..c4f49c8bfffab1d96b95748d33c0fb2c573c81bb 100644 (file)
@@ -4872,7 +4872,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;
index b22e4d61e70071f31779b9109842d4e8f98b8330..94813a381707386d4a4924f37d96570ee1eaefdd 100644 (file)
@@ -896,6 +896,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);
 }