cc1: warnings being treated as errors
libs/esl/src/esl.c: In function "esl_recv_event":
libs/esl/src/esl.c:1190: error: array subscript is above array bounds
libs/esl/src/esl.c:1227: error: array subscript is above array bounds
Clamp handle_recv() return value to safe values.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
On SIG Down we must not fail a call instead try hunting for another.
The only time we can fail the call and not bother hunting is
if sng_cc_resource_check fails.
Took out configuration retry as the config code is now
fixed in sng_ss7 library. Transaction id fix.
Unit Tested:
NSG UP -- start full load
kill NSG
NSG UP again on full load
make sure it comes up fine.
before hanging up the freetdm channel by force
seems to have a memory leak. I have increased the timeout
to 30sec and made the print statement WARNING level.
Where FS does not hangup the channel with in 3sec.
Without this fix, it was possible that 2 FS sessions
use the single span/chan freetdm session.
Merged the feature from git master of freetdm
SUSPEND will not only change the return state in few
cases.
I have retested all test cases from previous 2 commits.
What is missing is timer for each Tx Event. RSC,BLO,UBL.
Its possible to loose a message from Slave via relay to Master.
If that ever occours we will not know what state we are in.
Thus we need a timer that will re-transmit a packet if
it does not get acknowledged.
changed parameter name from cpu_reset_alarm_threshold to cpu_clear_alarm_threshold
(old parameter name still valid for backwards compatibility in configuration files)
used to clear ckt_flags, this was wrong.
if ctk_flags are blindly cleard a PAUSE might be cleared.
changed the code to clear only TX RESET and try to reset again.
Release Collision
If we get out of sync with other side we must
reset the circuit.
This condition occoured at 1+3 test box
Local Management Block
Its possible for stack to send us a BLO indicating to us
that we are local blocked. This case never worked and
we would get stuck there forever.
If we never manaully sent a LOCAL block, the BLO from
the stack will be acked and then unblocked.
This condition occoured at 1+3 test box
From previous commit, failed to clear the done flag _DN
which cause SUSPEND to think that there was a block
pending, causing state to remain in RESTART
S UP -> relay down -> Tx AIS -> relay up -> Tx AIS off
-> confirm all back up
-> In this condition BLO will not go out due to PAUSE
S UP -> Tx AIS -> relay down -> Tx AIS off -> relay up
-> confirm all back up
-> In this condition UBL will not go out due to PAUSE
Visually status of channels will only be DOWN once all resets/blocks are cleared.
Therefore if any reset/block is active on a channel, the channel state will be in RESTART not DOWN.
Logic Change
SUSPENDED
-> Originally used as intermediate state. Purpose is to handle a condition
from any state and go back to the previous state.
Conditions: such as block/ucic.
-> Updated logic is that SUSPEND will be smart enough not to
go back to just any state. SUSPEND will only go back to
UP - if call is still up
RESTART - if for any reason singaling is not up due to
blocks/resets/etc...
DOWN - if signaling is UP - no resets/blocks
In this case we avoid infinite loops due to state jumping
from STATE->SUSPEND->STATE->SUSPEND
HANGUP_COMPLETE
-> If call is in use and a RESET comes on a call
the RESTART state will first try the HANGUP_COMPLETE state.
HANGUP_COMPLETE will Tx RSC and wait for it.
Reset Response handle was updated if current state HANGUP/HANGUP_COMPLETE
go back to RESTART state. Which will call HANGUP COMPLETE due to
channel in usage and HANDLE_COMPLETE will clear RESET condition and go back to DOWN
TERMINATING
-> This state is used to hangup a call. Sends a signal to FS.
-> Usually TERMINATING state stays in TERMINATING until FS comes back.
-> I added a condition in case of RESET on the line though TERMINATING
will go back to RESTART.
This allows us to process RESET commands even though we are
in the middle of hanging up.
Block Handler
If BLO is received on circuit is already blocked,
we failed to trasmit BLA. We should always ack the BLO
even though it was alrady in blocked state.
Fixed & Tested
S UP --> place call --> relay down --> hangup --> relay up-->
Confirm that call is hungup properly.
In this condition, on relay up the circuit is put into RESET.
Since circuit is still in use, it will HANGUP first, then RESET
then clear pending BLOCK.
S UP --> place call -> Tx RSC on call.
Used to cause infitie loop
Confirm call is cleard properly
Re-Tested
S UP --> place call -> Rx RSC on call
Confirm call is cleard properly
S UP --> place call -> Rx BLO -> hangup -> place call
Confirm call cannot be placed
Tx UBL
Confirm call can be placed
S UP --> place call -> Rx BLO -> Tx BLO -> hangup -> place call
Confirm call cannot be placed
Tx UBL
Confirm call cannot be placed
Rx UBL
Confirm call can be placed
S UP --> place call -> relay down --> Rx BLO on channel from telco
--> relay up
Confirm that relay detects the BLO channels even though relay was down
Tx AIS -> S Start -> Confirm HW block -> Tx AIS off
-> Confirm hw block clear and UP
S UP -> Tx AIS -> Confirm HW block -> Tx AIS off
-> confirm hw block clear and UP
S UP -> relay down -> Tx AIS -> relay up -> Tx AIS off
-> confirm all back up
-> In this condition BLO will not go out due to PAUSE
S UP -> Tx AIS -> relay down -> Tx AIS off -> relay up
-> confirm all back up
-> In this condition UBL will not go out due to PAUSE
M UP -> S UP
M Down -> S UP -> M UP
M UP -> S UP -> relay down -> relay up
M UP -> S UP -> Kill M -> M UP
M Up -> S UP -> relay down -> M link down -> relay up -> M link up
Redmine Bug#1966
IAM ->
<-REL
<-ACM
<-ANM
ACM sets the reset flag
ANM sets the group reset flag
when both reset flags are set we got into infinite loop
No more "invalid span", now it's either "'foo' not a libpri span" or
"'foo' span not found" which makes it a lot more useful.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_handle.c
cc1: warnings being treated as errors
src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_handle.c: In function
'handle_con_ind':
src/ftmod/ftmod_sangoma_ss7/ftmod_sangoma_ss7_handle.c:255: warning: format '%x'
expects type 'unsigned int', but argument 3 has type 'U32'
make[6]: *** [ftmod_sangoma_ss7_la-ftmod_sangoma_ss7_handle.lo] Error 1
cpg_on_progress_media is default to TRUE if not xml option exists.
transparent_iam_max_size added to ccspan. Gloal value is used
if transparent_iam_max_size is not in ccSpan.
The latter is a well known automake variable, used
to set (per-Makefile) automake options and supported
since the beginning of time (= automake 1.4).
The former is a made-up variable that doesn't really
do anything.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
The latter is a well known automake variable, used
to set (per-Makefile) automake options and supported
since the beginning of time (= automake 1.4).
The former is a made-up variable that doesn't really
do anything.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
The latter is a well known automake variable, used
to set (per-Makefile) automake options and supported
since the beginning of time (= automake 1.4).
The former is a made-up variable that doesn't really
do anything.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
The latter is a well known automake variable, used
to set (per-Makefile) automake options and supported
since the beginning of time (= automake 1.4).
The former is a made-up variable that doesn't really
do anything.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
The latter is a well known automake variable, used
to set (per-Makefile) automake options and supported
since the beginning of time (= automake 1.4).
The former is a made-up variable that doesn't really
do anything.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
Fixed hw alarm handling: physical ids were not used which caused alarms
read wrong.
Tested sip hold
Group blocks/unblock
Group reset
Link down-> block -> unblock
FS start with link down then link up
FS start with link up, take link down and up -> make incoming call
This fixes a "AX_COMPILER_VENDOR: command not found" error on
systems with older autotools versions (CentOS 5.x in this case).
Not a problem on newer auto* toolchains, they either ignore
acinclude.m4 completely or handle it in a different way.
(In fact, acinclude.m4 is not even needed for the one on CentOS 5,
but we'll keep it for now.)
Tested-on: CentOS 5.7 x86_64 autoconf 2.59 / automake 1.9.6 / libtool 1.5.22
Tested-on: Gentoo 20111031 x86_64 autoconf 2.68 / automake 1.11 / libtool 2.4
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
* FreeTDM modules using the old FTDM_SPAN_STATE_CHANGE flag should be updated *
* until then, they are still vulnerable to deadlock situations *
* Modules pending update: (ftmod_analog, ftmod_libpri, ftmod_isdn) *
* Fixes Sangoma redmine ticket #1791 0 FTDM span stop deadlock *
* FreeTDM modules using the old FTDM_SPAN_STATE_CHANGE flag should be updated *
* until then, they are still vulnerable to deadlock situations *
* Modules pending update: (ftmod_analog, ftmod_libpri, ftmod_isdn) *
* Fixes Sangoma redmine ticket #1791 0 FTDM span stop deadlock *
* FreeTDM modules using the old FTDM_SPAN_STATE_CHANGE flag should be updated *
* until then, they are still vulnerable to deadlock situations *
* Modules pending update: (ftmod_analog, ftmod_libpri, ftmod_isdn) *
* Fixes Sangoma redmine ticket #1791 0 FTDM span stop deadlock *
This fixes all build errors.
(Stand-alone build of FreeTDM worked fine, for some
i-don't-really-want-to-know strange reason).
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
Needed for the mISDN/mISDNif.h header structs, linux/types.h only
provides them for kernel code:
In file included from src/ftmod/ftmod_misdn/ftmod_misdn.c:51:
/usr/include/mISDN/mISDNif.h:296: error: expected specifier-qualifier-list before 'u_int'
/usr/include/mISDN/mISDNif.h:306: error: expected specifier-qualifier-list before 'u_int'
/usr/include/mISDN/mISDNif.h:339: error: expected ')' before 'nr'
...
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
The CLI prompt and any text-in-progress now stays cleanly below log
messages and other received output from FS.
This also implements hardcoded prompt coloring.
libteletone headers include each other, use #include ""
to look in the local dir rather than the include search path.
Unbreaking all of my (still) external FreeTDM projects.
Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
This avoids hanging up a device that is no longer attached to the session, in the
weird situation where the FreeSWITCH core takes an awful lot of time (more than 3 seconds)
to come around to acknowledge the SIGEVENT_STOP signal.
- Misc fixes to log messages to aid debugging
- Added ftdm ioread command to read media from the channel
- Modified the ftdm_channel_open() API to return FTDM_EBUSY if the channel is already open