This change allows the format of the EAGI audio pipe to be changed by
setting the dialplan variable 'EAGI_AUDIO_FORMAT' to the name of one of
the loaded formats.
ASTERISK-26124 #close
Change-Id: I7a10fad401ad2a21c68c2e7246fa357d5cee5bbd
Documented the 'beep' option in both the parameters list and the command
description.
ASTERISK-23839 #close
Change-Id: I4970395c922dbdce3f7cf0f56d5b065ec9aa53ea
Explicitly check that the appropriate number of arguments were passed to
SET VARIABLE before attempting to reference them. Also initialize the
arguments array to zeroes before populating it.
ASTERISK-22432 #close
Change-Id: I5143607d80a2724f749c1674f3126b04ed32ea97
If the generated XML documentation for a command does not end with a \n,
the postamble of the usage message does not appear on its own line.
ASTERISK-25662 #close
Change-Id: If190f1e9e37fe215fed95897d78d4a6e142b0020
Some devices separate format attributes with a semicolon followed by a
space, so trim blanks before trying to match them.
ASTERISK-27008 #close
Change-Id: Ia44cb2e4fef5c73dc541a29da79cb0e19c22d9cc
A change was done which added an 'in_call' flag to queue
members that was set to true while talking to an agent.
Unfortunately in practice this does not accurately reflect
whether they are talking to an agent or not. If a Local
channel is involved and a transfer is performed then the
app_queue application would incorrectly think the agent
was still in a call with the caller. This was done to
fix a race condition between an agent becoming available
by device state and the checking of the last call information
for the wrapup time. There was a small window where the
last call information would be the previous value instead
of the new one.
This change goes about fixing the original issue in a
different way by considering the call completed if device
state is received which would make the agent available
and if they are currently in a call. If this occurs the
last call information is updated before the agent becomes
available ensuring that old information is not present
when checking if the member should be called. This also
improves the transfer situation by actually updating
and enforcing the wrapup time.
ASTERISK-26399
ASTERISK-26400
ASTERISK-26715
ASTERISK-26975
Change-Id: Ife1cb686e3173b3a6d368601adef9aff69d4beea
When user leaves a conference, its channel calls async_play_sound_file()
in order to play the name announcement and then unlinks the sound file.
The async_play_sound_file() function adds a task to conference playback queue,
which then runs playback_common() function in a different thread.
It leads to a race condition when, in some cases, channel thread may unlink
the sound file before playback_common() had a chance to open it.
This patch creates a file deletion task, that is queued after playback.
ASTERISK-27012 #close
Change-Id: I412f7922d412004b80917d4e892546c15bd70dd3
When using rtcp mux if an rtcp payload came in it would still use the srtp
unprotect algorithm instead of the srtp unprotect rtcp method. Since rtcp
data was being passed to the rtp unprotect method this would result in an
error.
This patch ensures that the correct unprotect method is chosen by making
sure the passed in rtcp flag is appropriately set when rtcp mux is enabled
and an rtcp payload is received.
ASTERISK-26979 #close
Change-Id: Ic5409f9d1a267f1d4785fc5aed867daaecca6241
If we are offered or are offering RTCP-MUX, don't consider RTCP ICE
candidates. This confuses certain browsers (current Firefox for
example) and causes intial audio setup delays.
ASTERISK-26982 #close
Change-Id: Ifeaf47e83972fe8dbe58b7fb3d6d1823400cfb91
Additional variable to work alongside QUEUE_MAX_PENALTY and QUEUE_MIN_PENALTY,
including an extra parameter in queuerules.conf. This value causes lower
Agent penalty values to "raise up" so that they can join higher penalty agents
and be treated equally after a period of time.
ASTERISK-26995 #close
Change-Id: If1c6421a983667a5ac4c359f6dac25b212b4c459
The while(1) loop in skinny_session wasn't checking for EOF so
a packet that was longer than a header but still truncated
would spin the while loop infinitely. Not only does this
permanently tie up a thread and drive a core to 100% utilization,
the call of ast_log() in such a tight loop eats all available
process memory.
Added poll with timeout to top of read loop
ASTERISK-26940 #close
Reported-by: Sandro Gauci
Change-Id: I2ce65f3c5cb24b4943a9f75b64d545a1e2cd2898
If the channel does not have multi-stream support then this application acts
just like app_echo. If it does have multi-stream support then each stream is
echoed back to itself (one-to-one).
If a "num" is specified, then a new topology is made that contains clones (from
the channel's topology) of all media types that are not equal to the given
"type". If the media type differs then the first stream matching the "type" is
cloned into the new topology and then up to "num" - 1 of the same stream are
also cloned into it. Any additional streams from the original topology matching
the "type" are subsequently ignored (i.e. not added to the new topology).
For this same case when a frame is read from a stream that frame is still
echoed back like before, but now that frame is also echoed out to the
additional streams that matched on the specified "type".
ASTERISK-26997 #close
Change-Id: I254144486734178e196c7f590a26ffc13543ff2c
Added functions that convert a string to an unsigned integer or unsigned long.
A couple of unit test were also created to test the routines. The reasons for
adding these conversion utilities (and hopefully eventually more) are as
follows:
* Conversion routines are functionally contained with consistent and
better error checking
* The function names offer a better description of what is happening
* It encourages code reuse for easier bug fixing at a single source
* It's simpler to use
* It's unit testable
For instance, currently in a lot of places when converting to an integer or
similar the "sscanf" function is used. When using "sscanf" it may not be
immediately clear what's happening as it lacks semantic naming. Limited error
checking is usually done as well. For example, most of the time a check is done
to make sure the value converted, but does not check for overflows or negative
valued conversions when converting unsigned numbers.
Why use/wrap "strtoul" and not "sscanf" then? Primarily, it lacks some of the
built in error handling that "strtoul" has. For instance "strtoul" contains
overflow checks. Less so, but can still factor as reasons, "sscanf" is slightly
more complex in its use. And maybe a bit controversial, but it may be ("big if")
potentially slower than "strtoul" in some cases.
Change-Id: If7eaca4a48f8c7b89cc8b5a1f4bed2852fca82bb
When manipulating flags on a channel the channel has to be
locked to guarantee that nothing else is also manipulating
the flags. This change introduces locking where necessary to
guarantee this. It also adds helper functions that manipulate
channel flags and lock to reduce repeated code.
ASTERISK-26789
Change-Id: I489280662dba0f4c50981bfc5b5a7073fef2db10
Retransmissions of an initial INVITE could be queued in the serializer
before we have processed the first INVITE message. If the first INVITE
message doesn't get completely processed before the retransmissions are
seen then we could try to setup the same call from the retransmissions. A
symptom of this is seeing a (key exists) message associated with an
INVITE. An earlier change attempted to address this kind of problem by
calculating a distributor serializer to use for unassociated messages.
Part of that change also made incoming calls keep using that distributor
serializer. (ASTERISK-26088) However, some leftover code was still
deferring the INVITE processing to the session's serializer even though we
were already in that serializer. This not only is unnecessary but would
cause the same call resetup problem.
* Removed the code to defer processing the initial INVITE to the session's
serializer because we are already running in that serializer.
ASTERISK-26998 #close
Change-Id: I1e822d82dcc650e508bc2d40d545d5de4f3421f6
* changes:
SDP: Make process possible multiple fmtp attributes per rtpmap.
SDP: Explicitly stop a RTP instance before destoying it.
SDP: Rework merge_capabilities().
SDP: Update ast_get_topology_from_sdp() to keep RTP map.
This option was added to turn off notifying the progress details
on Blind Transfer. If this option is not set then the chan_pjsip
will send NOTIFY "200 OK" immediately after "202 Accepted".
Some SIP phones like Mitel/Aastra or Snom keep the line busy until
receive "200 OK".
ASTERISK-26333 #close
Change-Id: Id606fbff2e02e967c02138457badc399144720f2
There are 2 places in app_queue.c that log EXITEMPTY event: one in
wait_our_turn, and another one in queue_exec in the loop trying to
call an agent after wait_our_turn.
In most cases it leads to logging EXITEMPTY twice.
ABANDON is also logged on two places, and in the rare case when an agent
and caller hang up simultaneously it's also possible to get duplicates
in queue_log.
This commit changes wait_our_turn to return -1 ("the caller should exit
the queue") instead of 0 ("the caller's turn has arrived") in case of
leaving when empty, so queue_exec skips the agent calling loop.
Also, leave_queue is now executed only once in this case, because 2nd
time is just a noop when the queue entry has already been removed.
Also, it sets qe->handled to -1 to indicate that the call was not
answered by an agent, but the necessary handling has already been done
in order to avoid logging an extra ABANDON entry.
ASTERISK-25665 #close
Reported by: Ove Aursand
Change-Id: I4578dd383bf2ac41589cf167865e8aaebcd4c11e
The sdp_state.remote_capabilities was only used inside merge_sdps() and
subsequent calls to merge_sdps() by re-INVITE's would leak them.
Change-Id: I0ceb7838ea044cc913e8ad4a255c39c9740ae0ce
When we optionally set the interface_address we are forcing the media to
go out a specific interface address. This allows us to optionally have
the media go out the interface that SIP signalling came in on or if we are
configured to have the media always go out a specific address.
Change-Id: I160d9fac322a075bd2557b430632544178196189
* Made sdp_add_m_from_rtp_stream() and sdp_add_m_from_udptl_stream()
handle generating disabled/declined streams.
* Added /main/sdp/sdp_merge_asymmetric unit test. It currently does not
check the offerer side negotiated SDP because that isn't the purpose of
this patch and there is much to be done to handle declined/dummy streams.
* Added T.38 image streams to the /main/sdp/sdp_merge_symmetric and
/main/sdp/sdp_merge_crisscross unit tests.
Change-Id: Ib4dcb3ca4f9a9133b376f4e3302f9a1f963f2b31
* Tried to give better variable names.
* Made our SDP answer use the offer's RTP payload types as the SDP RFC
says we SHOULD.
* Updating the local topology now takes the stream format caps. We are
likely preparing to send an offer.
Change-Id: I34d3be8e3036402a8575ffcae3eebc5ce348d7c0
This change uses the functions provided by OpenSSL to query
and better construct error messages for situations where
the connection encounters a problem.
ASTERISK-26606
Change-Id: I7ae40ce88c0dc4e185c4df1ceb3a6ccc198f075b
It is possible to initialize a valid config without a capath
or cafile definition. This will cause a crash on a reload.
This fix ensures capath is always allocated.
ASTERISK-26983 #close
Change-Id: I63ff715d9d9023427543a5b8a4ba7b0d82533c12