[asterisk-ss7] chan_zap.c patch

Matthew Fredrickson creslin at digium.com
Wed Feb 21 10:00:12 MST 2007


It's probably because of a "bug" in your configs.  The way you would to 
it properly is this:
cicbeginswith=1
channel=1-15
cicbeginswith=17
channel=17-31

It seems to be a nonintuitive way (for most people) to do channel to 
CIC mapping.  Maybe this might be an area worth spending some time on 
improving.

Matthew Fredrickson

On Feb 21, 2007, at 10:33 AM, Alexandru Pirvulescu wrote:

> Hello,
>
> The September/October version of SS7 implementation worked, but today 
> I've found out that the current trunk version is not working.
> What is happening:
>
> If I have channel=>1-15 and channel=>17-31 in /etc/zapata.conf the 
> reset code will send GRS to CICs from 1 to 30 (which is wrong).
> First, I thought that the break at channel 16 is ignored (which I 
> repeat, worked). The code is looking if the next zt_pvt->cic is the 
> following number after current and if it is not it sends a group reset 
> on the collected group (1-15 or 17-31). So, the problem was somewhere 
> at the ->cic member, which was ALWAYS the next number in sequence.
>
> Now, after digging more into the code, I've found that the CIC number 
> is taken incrementally (and 16 is a valid CIC number in this case) in 
> mkintf().
>
> I've patched chan_zap.c to set ->cic value to channel and it works 
> like a charm.
>
> Here is the patch, if any committer interested to put in the trunk:
>
> # svn diff channels/chan_zap.c
> Index: channels/chan_zap.c
> ===================================================================
> --- channels/chan_zap.c (revision 55913)
> +++ channels/chan_zap.c (working copy)
> @@ -7538,7 +7538,8 @@
>                                         return NULL;
>                                 }
> -                               tmp->cic = cur_cicbeginswith++;
> +                               tmp->cic = channel;
> +                               cur_cicbeginswith++;
>                                 tmp->ss7 = ss7;
>                                 tmp->ss7call = NULL;
>
>
> Regards,
> Alex
>
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
>
> asterisk-ss7 mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-ss7



More information about the asterisk-ss7 mailing list