From afb3f35a8287623a82222e5d04f37b6938f0e2be Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Thu, 24 May 2007 18:16:04 +0000 Subject: [PATCH] Steps towards parsing NI2 Setup message. git-svn-id: http://svn.openzap.org/svn/openzap/trunk@146 a93c3328-9c30-0410-af19-c9cd2b2d52af --- libs/openzap/src/Makefile | 5 ++++- libs/openzap/src/isdn/nationalie.c | 4 ++-- libs/openzap/src/isdn/nationalmes.c | 5 +++++ 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/libs/openzap/src/Makefile b/libs/openzap/src/Makefile index 1703dfd9df..f913e93e65 100644 --- a/libs/openzap/src/Makefile +++ b/libs/openzap/src/Makefile @@ -57,6 +57,9 @@ isdn/nationalStateNT.o \ isdn/nationalStateTE.o \ isdn/Q932mes.o +HEADERS=isdn/include/Q931.h \ + include/openzap.h + PWD=$(shell pwd) INCS=-I$(PWD)/include -I$(PWD)/isdn/include CFLAGS=$(ZAP_CFLAGS) $(INCS) @@ -67,7 +70,7 @@ include general.makefile $(ZAP_MODS) all: $(MYLIB) -$(MYLIB): $(OBJS) +$(MYLIB): $(OBJS) $(HEADERS) ar rcs $(MYLIB) $(OBJS) ranlib $(MYLIB) diff --git a/libs/openzap/src/isdn/nationalie.c b/libs/openzap/src/isdn/nationalie.c index b6e2446350..184c11aa18 100644 --- a/libs/openzap/src/isdn/nationalie.c +++ b/libs/openzap/src/isdn/nationalie.c @@ -66,10 +66,10 @@ the current IE. *****************************************************************************/ -#define Q931MoreIE() (Octet+Off - 2 < IESize) +#define Q931MoreIE() (Octet+Off - 2< IESize) #define Q931IESizeTest(x) {\ - if(Octet+Off-2 != IESize)\ + if(Octet + Off - 2!= IESize)\ {\ Q931SetError(pTrunk,x, Octet, Off);\ return x;\ diff --git a/libs/openzap/src/isdn/nationalmes.c b/libs/openzap/src/isdn/nationalmes.c index 23eb68d185..971016167f 100644 --- a/libs/openzap/src/isdn/nationalmes.c +++ b/libs/openzap/src/isdn/nationalmes.c @@ -159,6 +159,11 @@ L3INT nationalUmes_Setup(Q931_TrunkInfo_t *pTrunk, L3UCHAR *IBuf, Q931mes_Generi break; case nationalie_GENERIC_DIGITS: /* TODO: Implement this ie */ + IOff = IOff + 4; + break; + case Q931ie_SHIFT: + /* TODO: Implement this ie */ + IOff++; break; default: return Q931E_ILLEGAL_IE;