summaryrefslogtreecommitdiff
path: root/channels/misdn/isdn_msg_parser.c
diff options
context:
space:
mode:
authorChristian Richter <christian.richter@beronet.com>2006-04-04 19:09:26 +0000
committerChristian Richter <christian.richter@beronet.com>2006-04-04 19:09:26 +0000
commitd7a839a2997e45b4d037fb150e12b1d4ea1a1754 (patch)
tree76e5948654b22e04412a523f65040f437f1f3ee8 /channels/misdn/isdn_msg_parser.c
parentf8f83ff9b894fac813b2748afecc578cbe335639 (diff)
fixed some essential segfaults happening under heavy load. Added a bit more error handling if we receive wrong data form mISDN (e.g. if we crashed before => handle_err() ). Added first steps to implement the parseing of the connected party number.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/misdn/isdn_msg_parser.c')
-rw-r--r--channels/misdn/isdn_msg_parser.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/channels/misdn/isdn_msg_parser.c b/channels/misdn/isdn_msg_parser.c
index 7ae9a5369..c22575540 100644
--- a/channels/misdn/isdn_msg_parser.c
+++ b/channels/misdn/isdn_msg_parser.c
@@ -333,10 +333,17 @@ void parse_connect (struct isdn_msg msgs[], msg_t *msg, struct misdn_bchannel *b
int HEADER_LEN = nt?mISDNUSER_HEAD_SIZE:mISDN_HEADER_LEN;
CONNECT_t *connect=(CONNECT_t*)((unsigned long)(msg->data+HEADER_LEN));
+ int type,plan,pres,screen;
+ char connected_pn[32];
+
bc->ces = connect->ces;
bc->ces = connect->ces;
dec_ie_progress(connect->PROGRESS, (Q931_info_t *)connect, &bc->progress_coding, &bc->progress_location, &bc->progress_indicator, nt, bc);
+
+ dec_ie_connected_pn(connect->CONNECT_PN,(Q931_info_t *)connect, &type, &plan, &pres, &screen, connected_pn, 31, nt, bc);
+
+ cb_log(1,bc->port,"CONNETED PN: %s cpn_dialplan:%d\n", connected_pn, type);
#if DEBUG
printf("Parsing CONNECT Msg\n");