Tzafrir Cohen [Wed, 2 Oct 2013 18:28:03 +0000 (18:28 +0000)]
man pages for astdb2bdb and astdb2sqlite3
Review: https://reviewboard.asterisk.org/r/2898/
........
Merged revisions 400279 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 400281 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400282
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Wed, 2 Oct 2013 17:12:49 +0000 (17:12 +0000)]
MALLOC_DEBUG: Fix some misuses of free() when MALLOC_DEBUG is enabled.
* There were several places in ARI where an external library was mallocing
memory that must always be released with free(). When MALLOC_DEBUG is
enabled, free() is redirected to the MALLOC_DEBUG version. Since the
external library call still uses the normal malloc(), MALLOC_DEBUG
complains that the freed memory block is not registered and will not free
it. These cases must use ast_std_free().
* Changed calls to asprintf() and vasprintf() to the equivalent
ast_asprintf() and ast_vasprintf() versions respectively.
........
Merged revisions 400270 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400271
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Wed, 2 Oct 2013 17:10:39 +0000 (17:10 +0000)]
sig_ss7: Fix compiler warnings.
........
Merged revisions 400268 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400269
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Wed, 2 Oct 2013 16:23:34 +0000 (16:23 +0000)]
Reduce channel snapshot creation and publishing by up to 50%.
This change introduces the ability to stage channel snapshot
creation and publishing by suppressing the implicit creation
and publishing that some functions have. Once all operations
are executed the staging is marked as done and a single snapshot
is created and published.
Review: https://reviewboard.asterisk.org/r/2889/
........
Merged revisions 400265 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400266
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Wed, 2 Oct 2013 15:33:56 +0000 (15:33 +0000)]
Fix a random one way audio issue in PJSIP.
Due to the asynchronous design of the PJMEDIA SDP negotiator it was possible for
the SDP to be negotiated *after* a channel was created and after it was being wait
on by an application. It is only after negotiation occurs that the file descriptors
for RTP are placed on the channel. Since the channel was already being waited on
these file descriptors were not monitored, causing incoming media to never be read.
This change wakes up any application waiting on the channel so that added file
descriptors end up being monitored.
(closes issue AST-1227)
Reported by: John Bigelow
........
Merged revisions 400256 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400257
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Wed, 2 Oct 2013 15:24:16 +0000 (15:24 +0000)]
Allow specifying a channel to dial an extension and context in an ARI dial operation.
(issue ASTERISK-22625)
Reported by: Scott Griepentrog
........
Merged revisions 400254 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400255
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Wed, 2 Oct 2013 14:13:55 +0000 (14:13 +0000)]
Retrieve and store the hostname only once so multiple threads do not potentially initialize it at the same time.
........
Merged revisions 400245 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400246
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 1 Oct 2013 21:19:13 +0000 (21:19 +0000)]
chan_dahdi: Fix analog parking using flash-hook.
Transferring an analog call using a flash-hook to parking would fail to
park the call and result in an invalid ao2 object unref.
* Park the correct bridged channel.
........
Merged revisions 400236 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400237
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 1 Oct 2013 16:44:22 +0000 (16:44 +0000)]
Features: Rearm the parking config options have moved warning for each reload.
........
Merged revisions 400227 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400228
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Tue, 1 Oct 2013 15:54:05 +0000 (15:54 +0000)]
Filter out internal channels for bridge leave messages and parked call messages
Granted, if you manage to park a Conference announcer channel, something has
gone horrifically wrong.
........
Merged revisions 400217 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400218
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Mon, 30 Sep 2013 21:40:36 +0000 (21:40 +0000)]
configuration samples: Pull all parking related stuff out of features.conf
This patch also adds documentation for parking from features.conf to
res_parking.conf
........
Merged revisions 400205 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400206
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Mon, 30 Sep 2013 19:58:19 +0000 (19:58 +0000)]
Parse arguments passed to the CDR_PROP function correctly
I can only blame this on a bad merge, because this in no way worked properly
the way it was written. Mea culpa. The function should now parse its arguments
correctly and function properly. (Note that the API used by the CDR_PROP
function has working unit tests... this was merely bad coding of the actual
registered function)
(closes issue ASTERISK-22613)
Reported by: Private Name
........
Merged revisions 400196 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400197
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Mon, 30 Sep 2013 19:53:50 +0000 (19:53 +0000)]
Remove spurious event raised when CDRs are reloaded
The Reload event is now raised by the module loading core. As such, the Reload
event in the CDR engine was a duplicate and not needed.
........
Merged revisions 400194 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400195
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Mon, 30 Sep 2013 18:55:27 +0000 (18:55 +0000)]
Multiple revisions 399887,400138,400178,400180-400181
........
r399887 | dlee | 2013-09-26 10:41:47 -0500 (Thu, 26 Sep 2013) | 1 line
Minor performance bump by not allocate manager variable struct if we don't need it
........
r400138 | dlee | 2013-09-30 10:24:00 -0500 (Mon, 30 Sep 2013) | 23 lines
Stasis performance improvements
This patch addresses several performance problems that were found in
the initial performance testing of Asterisk 12.
The Stasis dispatch object was allocated as an AO2 object, even though
it has a very confined lifecycle. This was replaced with a straight
ast_malloc().
The Stasis message router was spending an inordinate amount of time
searching hash tables. In this case, most of our routers had 6 or
fewer routes in them to begin with. This was replaced with an array
that's searched linearly for the route.
We more heavily rely on AO2 objects in Asterisk 12, and the memset()
in ao2_ref() actually became noticeable on the profile. This was
#ifdef'ed to only run when AO2_DEBUG was enabled.
After being misled by an erroneous comment in taskprocessor.c during
profiling, the wrong comment was removed.
Review: https://reviewboard.asterisk.org/r/2873/
........
r400178 | dlee | 2013-09-30 13:26:27 -0500 (Mon, 30 Sep 2013) | 24 lines
Taskprocessor optimization; switch Stasis to use taskprocessors
This patch optimizes taskprocessor to use a semaphore for signaling,
which the OS can do a better job at managing contention and waiting
that we can with a mutex and condition.
The taskprocessor execution was also slightly optimized to reduce the
number of locks taken.
The only observable difference in the taskprocessor implementation is
that when the final reference to the taskprocessor goes away, it will
execute all tasks to completion instead of discarding the unexecuted
tasks.
For systems where unnamed semaphores are not supported, a really
simple semaphore implementation is provided. (Which gives identical
performance as the original taskprocessor implementation).
The way we ended up implementing Stasis caused the threadpool to be a
burden instead of a boost to performance. This was switched to just
use taskprocessors directly for subscriptions.
Review: https://reviewboard.asterisk.org/r/2881/
........
r400180 | dlee | 2013-09-30 13:39:34 -0500 (Mon, 30 Sep 2013) | 28 lines
Optimize how Stasis forwards are dispatched
This patch optimizes how forwards are dispatched in Stasis.
Originally, forwards were dispatched as subscriptions that are invoked
on the publishing thread. This did not account for the vast number of
forwards we would end up having in the system, and the amount of work it
would take to walk though the forward subscriptions.
This patch modifies Stasis so that rather than walking the tree of
forwards on every dispatch, when forwards and subscriptions are changed,
the subscriber list for every topic in the tree is changed.
This has a couple of benefits. First, this reduces the workload of
dispatching messages. It also reduces contention when dispatching to
different topics that happen to forward to the same aggregation topic
(as happens with all of the channel, bridge and endpoint topics).
Since forwards are no longer subscriptions, the bulk of this patch is
simply changing stasis_subscription objects to stasis_forward objects
(which, admittedly, I should have done in the first place.)
Since this required me to yet again put in a growing array, I finally
abstracted that out into a set of ast_vector macros in
asterisk/vector.h.
Review: https://reviewboard.asterisk.org/r/2883/
........
r400181 | dlee | 2013-09-30 13:48:57 -0500 (Mon, 30 Sep 2013) | 28 lines
Remove dispatch object allocation from Stasis publishing
While looking for areas for performance improvement, I realized that an
unused feature in Stasis was negatively impacting performance.
When a message is sent to a subscriber, a dispatch object is allocated
for the dispatch, containing the topic the message was published to, the
subscriber the message is being sent to, and the message itself.
The topic is actually unused by any subscriber in Asterisk today. And
the subscriber is associated with the taskprocessor the message is being
dispatched to.
First, this patch removes the unused topic parameter from Stasis
subscription callbacks.
Second, this patch introduces the concept of taskprocessor local data,
data that may be set on a taskprocessor and provided along with the data
pointer when a task is pushed using the ast_taskprocessor_push_local()
call. This allows the task to have both data specific to that
taskprocessor, in addition to data specific to that invocation.
With those two changes, the dispatch object can be removed completely,
and the message is simply refcounted and sent directly to the
taskprocessor.
Review: https://reviewboard.asterisk.org/r/2884/
........
Merged revisions 399887,400138,400178,400180-400181 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400186
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Mon, 30 Sep 2013 18:52:44 +0000 (18:52 +0000)]
Blocked revisions 399306
........
Blocked revisions 399305
........
Fix Segfault When Syntax Of A Line Under [applicationmap] Is Invalid
When processing the lines under the [applicationmap] context in features.conf, a
segfault occurs from attempting to process a line with an invalid syntax
(basically missing most of the arguments).
Example:
[applicationmap]
automon=*6
* This patch moves the checking for empty arguments to before they are accessed.
* Also, checked the "todo" comment and removed it. Some applications do not
require arguments.
(closes issue ASTERISK-22416)
Reported by: CGI.NET
Tested by: CGI.NET
Patches:
asterisk-22416-check-syntax-first_v2.diff by Michael L. Young (license 5026)
Review: https://reviewboard.asterisk.org/r/2803
........
Merged revisions 399304 from http://svn.asterisk.org/svn/asterisk/branches/1.8
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400185
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kinsey Moore [Mon, 30 Sep 2013 15:57:11 +0000 (15:57 +0000)]
chan_sip: Allow Asterisk to retry after 403 on register
This adds a global option in chan_sip to allow it to continue
attempting registration if a 403 is received, clearing the cached nonce
and treating it as a non-fatal response. Normally, this would cause
registration attempts to that endpoint to stop.
This also adds a similar per-outbound-registration option to chan_pjsip
which allows the retry interval to be altered for 403 responses to
REGISTER requests.
(closes issue ASTERISK-17138)
Review: https://reviewboard.asterisk.org/r/2874/
Reported by: Rudi
........
Merged revisions 400137 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 400140 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 400141 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400142
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 22:57:17 +0000 (22:57 +0000)]
res_pjsip_notify: Add documentation
We forgot to add documentation for res_pjsip_notify, which would prevent it
from being loaded. Whoops.
This patch also updates res_pjsip_notify to use pjsip_notify.conf, which now
has its own sample file in the configs directory as well.
Review: https://reviewboard.asterisk.org/r/2835/
........
Merged revisions 400121 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400122
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 22:32:18 +0000 (22:32 +0000)]
res_rtp_asterisk: Correct erroneous lost packet information in RTCP reports
RTCP's calculation of the number of lost packets in an RTP stream is based on
that stream's sequence number count, the number of received packets, and how
many packets we expect to receive. When the SSRC for an RTP stream changes,
there can - and almost always will be - a large jump in the next packet's
timestamp and sequence number. If we don't reset the number of received
packets, sequence number count, and other metrics used by RTCP, the next RR/SR
report will use the previous SSRC's values to calculate the lost packet count
for the new SSRC - resulting in a very large number of lost packets.
This patch modifies res_rtp_asterisk such that, if it detects a SSRC change, it
will reset the various values used by the RTCP calculations. From the
perspective of RTCP, this appears as a new media stream - which is what it is.
Review: https://reviewboard.asterisk.org/r/2886/
(closes issue AST-1174)
Reported by: Thomas Arimont
........
Merged revisions 400089 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 400093 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 400108 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400117
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 22:13:57 +0000 (22:13 +0000)]
Add check for openSUSE when detecting bfd library
In ASTERISK-17842, some additional library checks were added to the configure
script so that the bfd library could be found on CentOS and Fedora systems.
As it turns out, openSUSE requires an additional library. This patch adds
another check to the configure script for openSUSE that will add that library.
Review: https://reviewboard.asterisk.org/r/2885/
(closes issue AST-1169)
Reported by: Guenther Kelleter
........
Merged revisions 400073 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 400075 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 400077 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400078
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 20:55:48 +0000 (20:55 +0000)]
CDR: Improve handling of parking; resolve assertion when originating into park
This patch covers two problems:
1) Currently, when a call is transferred into a parking lot from a bridge
(using either the blind transfer or one touch parking mechanisms), the
application fails to be set to "Park" in the resulting CDR record for
the parked channel. This is due to the ParkedCall message arriving before
the BridgeEnter for the channel entering the parking bridge. The ParkedCall
message isn't handled as the CDR for the channel has already been finalized
(due to the channel having left its two party bridge), and the BridgeEnter -
which creates the new CDR - doesn't have the parking information. This patch
modifies the behavior so that reception of a ParkedCall message will - if
not handled by a CDR chain - cause a new CDR to be created and put into the
Parking state.
2) It fixes a FRACK that occurred when a channel is originated into a parking
space. The DialedPending state - which occurs for both Dialed and Originated
channels - assumed that it couldn't handle the parking transitions due to it
having a Party B; however, Originated channels don't have a Party B. As such,
the existing CDR needs to transition into the parking state - this patch does
that.
Review: https://reviewboard.asterisk.org/r/2877/
(closes issue ASTERISK-22482)
Reported by: Richard Mudgett
........
Merged revisions 400062 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400063
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 20:39:10 +0000 (20:39 +0000)]
app_queue: Make manager events tolerant of Local channel shenanigans
app_queue currently attempts to handle Local channel optimizations in an effort
to provide accurate information in Stasis messages (and their corresponding
AMI events) as well as the Queue log. Sometimes, however, things don't go as
planned.
Consider the following scenario:
SIP/foo <-> L;1 <-> L;2 <-> SIP/agent
SIP/agent answers, triggering a Local channel optimization. app_queue will
normally do the following:
* Listen for the Local optimization events and update our agent accordingly
to SIP/agent in the queue log and messages
* When we get a hangup, publish the AgentComplete event based on our
information (SIP/foo and SIP/agent)
However, as with all things that depend on sanity from something as capricious
as Local channels, things can go wrong:
(1) SIP/agent immediately hangs up upon answering. This triggers a race
condition between termination messages coming from SIP/agent and the
ongoing Local channel optimization messages. (Note that this can also
occur with SIP/foo)
(2) In a race condition, Asterisk can (rarely) deliver the hangup messages
prior to the Local channel optimization.
In that case, the messages *may* arrive to app_queue in the following order:
* Hangup SIP/Agent
* Hangup SIP/foo
* Optimize L;1/L;2
* Hangup L;2
* Hangup L;1
When app_queue receives the hangup of the agent or the caller, it will attempt
to publish the AgentComplete event. However, it now has a problem - it thinks
its agent is the ;1 side of the Local channel, as it never received the
optimization event. At the same time, that channel is already gone. This
results in getting NULL from the Stasis cache. What's more, we can't really
wait for the optimization message, as we are currently handling the hangup
of the channel that the optimization event would tell us to use.
This patch modifies the behavior in app_queue such that, since we still have a
lot of pertinent queue information (interface, queue name, etc.), we now raise
the event with what information we know. The channels involved now may or may
not be present. Users will still at least get the "AgentComplete" event, which
"completes" the known Agent information.
Review: https://reviewboard.asterisk.org/r/2878/
(closes issue ASTERISK-22507)
Reported by: Richard Mudgett
........
Merged revisions 400060 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400061
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sat, 28 Sep 2013 20:27:23 +0000 (20:27 +0000)]
manager: Fix crash when appending a manager channel variable
In r399887, a minor performance improvement was introduced by not allocating
the manager variable struct if it wasn't used. Unfortunately, when directly
accessing an ast_channel struct, manager assumed that the struct was always
allocated. Since this was no longer the case, things got a bit crashy.
This fixes that problem by simply bypassing appending variables if the manager
channel variable struct isn't there.
........
Merged revisions 400058 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400059
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Fri, 27 Sep 2013 21:58:05 +0000 (21:58 +0000)]
app_cdr and res_parking: Fix some resource leaks.
* app_cdr left the ResetCDR application registered.
* res_parking leaked a ref to config global.
(closes issue ASTERISK-22566)
Reported by: Corey Farrell
Patches:
ASTERISK-22566-r2.patch (license #5909) patch uploaded by Corey Farrell
........
Merged revisions 400020 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400021
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Fri, 27 Sep 2013 21:44:42 +0000 (21:44 +0000)]
chan_sip: Increase some scratch buffer sizes dealing with caller id.
* Eliminated an unnecessary initialization in check_user_full().
(closes issue ASTERISK-22477)
Reported by: Michael Shepelev
........
Merged revisions 400013 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 400014 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 400015 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400016
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Sean Bright [Fri, 27 Sep 2013 19:18:55 +0000 (19:18 +0000)]
Remove some trailing whitespace and steal revision 400000.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400000
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Fri, 27 Sep 2013 18:28:41 +0000 (18:28 +0000)]
res_pjsip: crash when using localnet and external_signaling_address options
There was a collision of mod_data use on the transaction between using a nat
hook and an session response callback. During state change it was assumed
what was in the mod_data was nothing or the response callback. However, it
was possible for it to also contain a nat hook thus resulting in a bad cast
and a crash.
Added the ability to store multiple data elements in mod_data via a hash table.
In this instance, mod_data now stores a hash table of the two values that can
be retrieved using an associated string key.
(closes issue ASTERISK-22394)
Reported by: Rusty Newton
Review: https://reviewboard.asterisk.org/r/2843/
........
Merged revisions 399990 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399991
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Fri, 27 Sep 2013 17:46:16 +0000 (17:46 +0000)]
chan_sip: Reject calls on 200 OKs if no SDP has been received
When Asterisk receives a 200 OK in response to an invite, that peer should have
sent an SDP at some point by then. If the channel has never received an SDP,
media won't have been set and the remote address won't be known. Endpoints in
general should not be doing this. This patch makes it so that Asterisk will
simply hang up a call if it sends a 200 OK at this point. So far this odd
behavior for endpoints has only been observed in tests which involved manually
created SIP transactions in SIPp.
(closes issue ASTERISK-22424)
Reported by: Jonathan Rose
Review: https://reviewboard.asterisk.org/r/2827/
........
Merged revisions 399939 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399962 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399976 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399978
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Fri, 27 Sep 2013 17:11:22 +0000 (17:11 +0000)]
astobj2: Remove OBJ_CONTINUE support.
OBJ_CONTINUE was a strange feature that came into the world under
suspicious circumstances to support an abuse of the ao2_container by
chan_iax2. Since chan_iax2 no longer uses OBJ_CONTINUE, it is safe to
remove it.
The simplified code should help performance slightly and make
understanding the code easier.
Review: https://reviewboard.asterisk.org/r/2887/
........
Merged revisions 399937 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399938
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Fri, 27 Sep 2013 14:35:12 +0000 (14:35 +0000)]
Fix refleaks of ast_rtp_instance structures.
These refleaks were causing bridged calls not to close their RTP ports. Thus
a call would leave open 4 ports (RTP for party A, RTCP for party A, RTP for party
B, and RTCP for party B). This led to an eventual depletion of available RTP
ports.
........
Merged revisions 399924 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399925
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kinsey Moore [Fri, 27 Sep 2013 14:08:23 +0000 (14:08 +0000)]
Restore usefulness of the CEL Peer field
This change makes the CEL peer field useful again for BRIDGE_ENTER and
BRIDGE_EXIT events and fills the field with a comma-separated list of
all channels in the bridge other than the channel that is entering or
exiting the bridge.
Review: https://reviewboard.asterisk.org/r/2840/
(closes issue ASTERISK-22393)
........
Merged revisions 399912 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399913
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Thu, 26 Sep 2013 18:51:54 +0000 (18:51 +0000)]
pjsip: race condition in registrar
While handling a registration request a race condition could occur if/when two+
clients registered at the same time. This happened when one request obtained a
copy of the current contacts for an AOR and another request did the same before
the first request updated. Thus the second would update and overwrite the first
(or vice-versa depending on which actually updated first). In the case of it
being the same contact two "add" events would be raised.
pjsip registration handling is now serialized to alleviate this issue.
(closes issue AST-1213)
Reported by: John Bigelow
Review: https://reviewboard.asterisk.org/r/2860/
........
Merged revisions 399897 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399898
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Thu, 26 Sep 2013 14:13:37 +0000 (14:13 +0000)]
Adding a few words to the Dial option 'r' help text to clarify its tone argument description
........
Merged revisions 399874 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399875
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Wed, 25 Sep 2013 20:38:24 +0000 (20:38 +0000)]
chan_dahdi: CLI "core stop gracefully" has needless delay for PRI and SS7.
The PRI and SS7 link control threads are not stopped correctly when the
chan_dahdi.so module is unloaded. The link control threads pri_dchannel()
and ss7_linkset() are not awakened from a poll() to cancel the thread.
* Added a SIGURG signal after requesting the thread cancel to break the
link control thread poll() immediately.
For SS7 it was slightly worse, the link poll() timeout would always be
whatever was the last libss7 scheduled event time used. If no libss7
scheduled event was pending, the thread could run more often than
necessary.
* Set nextms to 60 seconds for the ss7_linkset() poll() if there is no
other libss7 scheduled event.
........
Merged revisions 399818 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399834 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399842 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399844
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Wed, 25 Sep 2013 19:43:43 +0000 (19:43 +0000)]
Broke the build - Fixing XML DTD violation added in r399782, missing <para> tags inside a <note>
........
Merged revisions 399798 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399799
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Michael L. Young [Wed, 25 Sep 2013 19:29:38 +0000 (19:29 +0000)]
chan_sip: Fix Realtime Peer Update Problem When Un-registering And Expires Header In 200ok
1st Issue
When a realtime peer sends an un-REGISTER request, Asterisk
un-registers the peer but the database table record still has regseconds and
fullcontact for the peer. This results in calls attempting to be routed to the
peer which is no longer registered. The expected behavior is to get
busy/congested when attempting to call an un-registered peer through the
dialplan.
What was discovered is that we are clearing out the peer's registration in the
database in parse_register_contact() when calling expire_register() but then
upon returning from parse_register_contact(), update_peer() is run which stores
back in the database table regseconds and fullcontact.
2nd Issue
The reporter pointed out that the 200 ok being returned by Asterisk
after un-registering a peer contains a Contact header with ;expires= and the
Expires header is not set to 0. This is actually a regression.
Tests were created for this second issue (ASTERISK-22548). The tests have been
reviewed and a Ship It! was received on those tests.
This patch does the following:
* Do not ignore the Expires header value even when it is set to 0. The patch
sets the pvt->expiry earlier on in the function so that it is set properly and
used.
* If pvt->expiry is 0, do not call update_peer since that means the peer has
already been un-registered and there is no need to update the database record
again since nothing has changed.
(closes issue ASTERISK-22428)
Reported by: Ben Smithurst
Tested by: Ben Smithurst, Michael L. Young
Patches:
asterisk-22428-rt-peer-update-and-expires-header.diff
by Michael L. Young (license 5026)
Review: https://reviewboard.asterisk.org/r/2869/
........
Merged revisions 399794 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399795 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399796 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399797
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Wed, 25 Sep 2013 18:38:34 +0000 (18:38 +0000)]
Fixing documentation for the configOption "external_media_address" of both Endpoints and Transports
Re-using some of Mark Michelson's text from an E-mail discussion for:
* Modifying synopsis for both options
* Adding description to both options
* Changing name of "external_media_address" for Endpoint configuration to "media_address" in anticipation of the option name being changed. (As it is not really specific to external destinations)
(issue ASTERISK-22405)
(closes issue ASTERISK-22405)
Reported by: Rusty Newton
Review: https://reviewboard.asterisk.org/r/2850/
........
Merged revisions 399781 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399782
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 24 Sep 2013 22:55:06 +0000 (22:55 +0000)]
astobj2: Made use OBJ_SEARCH_xxx identifiers as field enum values internally.
* Made ao2_unlink to protect itself from stray OBJ_SEARCH_xxx values
passed in.
........
Merged revisions 399749 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399750
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 24 Sep 2013 20:37:32 +0000 (20:37 +0000)]
chan_iax2: Prevent some needless breaking of the native IAX2 bridge.
* Clean up some twisted code in the iax2_bridge() loop.
* Add AST_CONTROL_VIDUPDATE and AST_CONTROL_SRCCHANGE to a list of frames
to prevent the native bridge loop from breaking.
* Passing the AST_CONTROL_T38_PARAMETERS frame should also allow FAX over
a native IAX2 bridge.
(issue ABE-2912)
Review: https://reviewboard.asterisk.org/r/2870/
........
Merged revisions 399697 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399708 from http://svn.asterisk.org/svn/asterisk/branches/11
For v12 and above this is really just documentation until IAX2 native
bridging is restored.
........
Merged revisions 399736 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399737
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Tue, 24 Sep 2013 19:22:30 +0000 (19:22 +0000)]
app_queue: Don't be quite so aggressive in initializing the array
We only need the first character.
........
Merged revisions 399695 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399696
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Tue, 24 Sep 2013 18:59:05 +0000 (18:59 +0000)]
app_queue: Initialize array holding MixMonitor exec options
If the channel variable MONITOR_EXEC is set, app_queue will pass the specified
execution parameters to the MixMonitor application when a queue is recorded.
If that channel variable is not set, the buffer that holds the escaped value
was not being initialized to NULL, and so would be passed to the MixMonitor
application with garbage. Hilarity ensued as app_mixmonitor attempted to
execute gobeldy-gook.
........
Merged revisions 399681 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399682
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Tue, 24 Sep 2013 18:10:20 +0000 (18:10 +0000)]
Fix a performance problem CDRs
There is a large performance price currently in the CDR engine. We currently
perform two ao2_callback calls on a container that has an entry for every
channel in the system. This is done to create matching pairs between channels
in a bridge.
As such, the portion of the CDR logic that this patch deals with is how we
make pairings when a channel enters a mixing bridge. In general, when a
channel enters such a bridge, we need to do two things:
(1) Figure out if anyone in the bridge can be this channel's Party B.
(2) Make pairings with every other channel in the bridge that is not already
our Party B.
This is a two step process. In the first step, we look through everyone in the
bridge and see if they can be our Party B (single_state_process_bridge_enter).
If they can - yay! We mark our CDR as having gotten a Party B. If not, we keep
searching. If we don't find one, we wait until someone joins who can be our
Party B.
Step 2 is where we changed the logic
(handle_bridge_pairings and bridge_candidate_process). Previously, we would
first find candidates - those channels in the bridge with us - from the
active_cdrs_by_channel container. Because a channel could be a candidate if it
was Party B to an item in the container, the code implemented multiple
ao2_container callbacks to get all the candidates. We also had to store them
in another container with some other meta information. This was rather complex
and costly, particularly if you have 300 Local channels (600 channels!) going
at once.
Luckily, none of it is needed: when a channel enters a bridge (which is when
we're figuring all this stuff out), the bridge snapshot tells us the unique
IDs of everyone already in the bridge. All we need to do is:
For all channels in the bridge:
If the channel is us or our Party B that we got in step 1, skip it
Compare us and the candidate to figure out who is Party A (based on some
specific rules)
If we are Party A:
Make a new CDR for us, append it to our chain, and set the candidate as
Party B
If they are Party A:
If they don't have a Party B:
Make a new CDR for them, append us to their chain, and us as Party B
Otherwise:
Copy us over as Party B on their existing CDR.
This patch does that.
Because we now use channel unique IDs to find the candidates during bridging,
active_cdrs_by_channel now looks up things using uniqueid instead of channel
name. This makes the more complex code simpler; it does, however, have the
drawback that dialplan applications and functions will be slightly slower as
they have to iterate through the container looking for the CDR by name.
That's a small price to pay however as the bridging code will be called a lot
more often.
This patch also does two other minor changes:
(1) It reduces the container size of the channels in a bridge snapshot to 1.
In order to be predictable for multi-party bridges, the order of the
channels in the container must be stable; that is, it must always devolve
to a linked list.
(2) CDRs and the multi-party test was updated to show the relationship between
two dialed channels. You still want to know if they talked - previously,
dialed channels were always ignored, which is wrong when they have
managed to get a Party B.
(closes issue ASTERISK-22488)
Reported by: Richard Mudgett
Review: https://reviewboard.asterisk.org/r/2861/
........
Merged revisions 399666 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399667
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Mon, 23 Sep 2013 12:03:18 +0000 (12:03 +0000)]
Fix crash in res_pjsip on load if error occurs, and prevent unloading of res_pjsip and res_pjsip_session.
During load time in res_pjsip if an error occurred the operation would attempt to rollback all
operations done during load. This is not permitted by PJSIP as it will assert if the operation has
not been done. This fix changes the code so it will only rollback what has been initialized already.
Further changes also prevent res_pjsip and res_pjsip_session from being unloaded. This is due to
limitations within PJSIP itself. The library environment can only be changed to a certain extent
and does not provide the ability, currently, to deinitialize certain required functionality.
(closes issue ASTERISK-22474)
Reported by: Corey Farrell
........
Merged revisions 399624 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399625
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Sat, 21 Sep 2013 04:49:26 +0000 (04:49 +0000)]
res_rtp_asterisk: Fix ref leaks in ast_rtcp_read().
Moved rtcp_report RAII_VAR declaration into the loop so it is unref'ed
after every loop. Moved message_blob to loop and switched it to a regular
variable. The regular variable was used since message_blob is used in a
very contained way.
(closes issue ASTERISK-22565)
Reported by: Corey Farrell
Patches:
rtcp_report-leak.patch (license #5909) patch uploaded by Corey Farrell
Tested by: Corey Farrell
........
Merged revisions 399607 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399608
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Sat, 21 Sep 2013 01:46:56 +0000 (01:46 +0000)]
media_index: Fix process_description_file() memory leak of file_id_persist.
........
Merged revisions 399596 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399597
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Sat, 21 Sep 2013 00:56:52 +0000 (00:56 +0000)]
features_config: Fix config ref leak of parkinglots.
This leak happend for just about every channel created.
........
Merged revisions 399585 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399586
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Sat, 21 Sep 2013 00:23:45 +0000 (00:23 +0000)]
app_queue: Fix json blob ref leak.
The json ref from queue_member_blob_create() was never released.
........
Merged revisions 399583 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399584
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Sat, 21 Sep 2013 00:17:56 +0000 (00:17 +0000)]
json: Make it obvious that ast_json_unref() is NULL safe.
It looked like the safety check was done after the NULL pointer was used.
........
Merged revisions 399576 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399578
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kinsey Moore [Fri, 20 Sep 2013 22:44:11 +0000 (22:44 +0000)]
Ensure global types in the config framework are initialized
If a config object was allocated but one of its global objects was
never encountered, then the global object's defaults were never
applied. Ensure that global objects are initialized properly upon
allocation instead of on configuration.
Review: https://reviewboard.asterisk.org/r/2866/
........
Merged revisions 399564 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399565 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399566
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Fri, 20 Sep 2013 22:06:07 +0000 (22:06 +0000)]
originate/call forwarding: Fix a crash when forwarding a call from originate
(closes issue ASTERISK-22487)
Reported by: David M. Lee
Review: https://reviewboard.asterisk.org/r/2868/
........
Merged revisions 399553 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399554
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Joshua Colp [Fri, 20 Sep 2013 16:18:42 +0000 (16:18 +0000)]
Add a missing session supplement unregistration in chan_pjsip for ACKs.
(closes issue ASTERISK-22453)
Reported by: Corey Farrell
Patches:
chan_pjsip_session_unregister_supplement.patch uploaded by Corey Farrell (license 5909)
........
Merged revisions 399531 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399533
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Fri, 20 Sep 2013 14:26:44 +0000 (14:26 +0000)]
Fix memory leak in logger.
Fixed a memory leak discovered in the logger where a temporary string buffer
was not being freed.
(closes issue ASTERISK-22540)
Reported by: John Hardin
........
Merged revisions 399513 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399514 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399515
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Thu, 19 Sep 2013 23:20:43 +0000 (23:20 +0000)]
optional_api: Make always use the standard malloc functions even with MALLOC_DEBUG.
........
Merged revisions 399501 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399503
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Thu, 19 Sep 2013 17:01:09 +0000 (17:01 +0000)]
chan_sip: Make direct media reinvites for T38 put Asterisk in the media path
Prior to this patch, Asterisk would incorrectly use the previous endpoint
addresses in SDP in spite of providing its own port. T38 is never meant to
be done through directmedia and Asterisk should always be in the media path
for these streams.
(closes issue ASTERISK-17273)
Reported by: Kevin Stewart
(closes issue ASTERISK-18706)
Reported by: Jeremy Kister
Review: https://reviewboard.asterisk.org/r/2853/
........
Merged revisions 399456 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399457 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399458 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399459
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kinsey Moore [Wed, 18 Sep 2013 20:04:14 +0000 (20:04 +0000)]
Fix jitter buffer log file creation
This adjusts '/'-to-'#' replacement to replace all instances of '/'
instead of just the first to ensure that the jitter buffer log file
gets the correct name as per Richard Kenner's suggestion.
(closes issue ASTERISK-21036)
Reported by: Richard Kenner
........
Merged revisions 399402 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399403 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399404 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399405
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Wed, 18 Sep 2013 17:23:49 +0000 (17:23 +0000)]
Update prep_tarball with new documentation files on the Asterisk wiki
This will now pull both a command reference for the version being prepared,
as well as an Admin Guide that applies to all versions of Asterisk.
(issue ASTERISK-22439)
Reported by: Olle Johansson
........
Merged revisions 399351 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399373 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399376 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399378
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Wed, 18 Sep 2013 17:21:39 +0000 (17:21 +0000)]
Add a WARNING in bridge_softmix when a timing module isn't loaded
If bridge_softmix fails to be created because no timing source is present in
Asterisk, this will currently fail gracefully but with (most likely) a generic
error message by whatever module tried to create the softmix bridge. This
patch adds a more explicit warning so you can actually diagnose and fix the
problem.
Review: https://reviewboard.asterisk.org/r/2857/
........
Merged revisions 399353 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399365 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399368
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Wed, 18 Sep 2013 17:15:53 +0000 (17:15 +0000)]
Make config framework able to reload module configs with multiple config files.
The config framework is supposed to be able to load configs that come from
multiple config files. The principle example is chan_sip's sip.conf and
users.conf. Unfortunately, it only does this correctly on initial load.
This patch causes the module's config to be reloaded entirely if any of
the config files change.
(closes issue ASTERISK-22009)
Reported by: Richard Mudgett
Review: https://reviewboard.asterisk.org/r/2859/
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399352
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Wed, 18 Sep 2013 14:56:22 +0000 (14:56 +0000)]
res_pjsip_messaging: Register message technology as pjsip
pjsip's message technology was being registered as 'sip', which was causing it
to not load due it conflicting with chan_sip's registered 'sip' technology for
messaging. It now registers as 'pjsip'. However, due to this change the "to"
field for outgoing pjsip messages need to be prefixed with 'pjsip:' instead of
'sip:'. Incoming messages to res_pjsip_messaging will automatically have their
"to" fields altered in order to accommodate the change. Outgoing messages also
handle changing it back to 'sip' before being sent so the pjsip library will
properly handle it.
(closes issue ASTERISK-22445)
Reported by: Matt Jordan
Review: https://reviewboard.asterisk.org/r/2833/
........
Merged revisions 399339 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399340
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Michael L. Young [Wed, 18 Sep 2013 00:13:23 +0000 (00:13 +0000)]
Fix Segfault In features-config.c When Application Has No Arguments
Some applications do not require arguments. Therefore, when parsing application
maps in features.conf, it is possible that app_data will be set to NULL.
* This patch sets app_data to "" if it is NULL.
Review: https://reviewboard.asterisk.org/r/2804
........
Merged revisions 399294 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399295
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Tue, 17 Sep 2013 23:10:49 +0000 (23:10 +0000)]
Change the "external_media_address" PJSIP endpoint option to "media_address".
The endpoint option does not apply to communication with external entities. Rather,
the option is applied to all communications with the endpoint. The external_media_address
transport configuration option may override the endpoint option if it turns out that
we are going to be communicating with an external entity.
Two things of note:
1) I have not updated the XML documentation. This is being taken care of by Rusty as part
of his work on issue ASTERISK-22405
2) This commit is likely to cause testsuite failures since there are tests that use the
external_media_address endpoint option, and they will need to be changed over. Well, I'm
planning to get that updated ASAP after this commit.
(closes issue ASTERISK-22528)
reported by Rusty Newton
........
Merged revisions 399283 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399284
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Tue, 17 Sep 2013 18:44:11 +0000 (18:44 +0000)]
Remote console: more output discrepancies
The remote console continued to have issues with its output. In this case CLI
command output would either not show up (if verbose level = 0) or would contain
verbose prefixes (if verbose level > 0) once log messages were sent to the
remote console. The fix now now adds verbose prefix data to all new lines
contained in a verbose log string.
(closes issue ASTERISK-22450)
Reported by: David Brillert
(closes issue AST-1193)
Reported by: Guenther Kelleter
Review: https://reviewboard.asterisk.org/r/2825/
........
Merged revisions 399267 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399268 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399269
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 17 Sep 2013 17:55:21 +0000 (17:55 +0000)]
Fix doxygen to use correct units of features.conf options.
........
Merged revisions 399257 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399258
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Tue, 17 Sep 2013 17:10:51 +0000 (17:10 +0000)]
Fix other timeouts (atxferloopdelay and atxfernoanswertimeout) to use seconds instead of milliseconds.
Thanks to Richard Mudgett for pointing this out.
........
Merged revisions 399247 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399248
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Tue, 17 Sep 2013 16:11:20 +0000 (16:11 +0000)]
Switch transferdigittimeout to be configured as seconds instead of milliseconds.
This was an unintentional consequence of the update of features.conf to use the
config framework in Asterisk 12. Thanks to Marco Signorini on the Asterisk
developers list for pointing out the problem.
........
Merged revisions 399237 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399238
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Tue, 17 Sep 2013 14:58:22 +0000 (14:58 +0000)]
Confbridge: empty conference not being torn down
Confbridge would not properly tear down an empty conference bridge when all
users were kicked via end_marked=yes and at least one user was also set to
wait_marked. This occurred because while end_marked users were being kicked
and at least one was also set to wait_marked then the leave wait_marked handler
would be called on that user, but there would be no waiting user (still
considered active). The waiting users would decrement and now be negative. The
conference would remain, but be put into an inactive state. The solution was
to move from the active list to the wait list, those users with wait_marked set
right before kicking. This allows both the active and wait users to decrement
correctly and the confbridge to tear down properly.
A crashed also occurred when trying to list the specific conference from the CLI.
This happened because the conference specified was invalid. Since the
conference properly tears down now there is no way to reference it thus
alleviating the crash as well.
(closes issue ASTERISK-21859)
Reported by: Chris Gentle
Review: https://reviewboard.asterisk.org/r/2848/
........
Merged revisions 399222 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399225 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399226
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Mon, 16 Sep 2013 18:36:22 +0000 (18:36 +0000)]
Fix module load errors for test_ari_model.so.
You cannot use a function pointer variable with an external function from
another dynamically loaded module because data variables are always
resolved even with RTLD_LAZY.
* Added wrapper functions for ast_ari_validate_int() and
ast_ari_validate_string() to use instead for the function pointer
variable.
(closes issue ASTERISK-22457)
Reported by: David M. Lee
........
Merged revisions 399207 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399208
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Mon, 16 Sep 2013 18:00:32 +0000 (18:00 +0000)]
app_speech_utils: Fix unresolved symbol ast_speech_get_setting().
Fixes regression introduced by -r374096.
* Made res_speech.export.in export ast_* symbols instead of specific
functions.
* Made app_speech_utils.c declare that it is dependent upon res_speech.
(issue ASTERISK-17136)
Reported by: Richard Kenner
........
Merged revisions 399197 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399198
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Mon, 16 Sep 2013 16:50:02 +0000 (16:50 +0000)]
chan_iax2: Fix saving the wrong expiry time in astdb.
When a new IAX2 client registers, the astdb database is updated with the
value of minregexpire defined in iax.conf instead of using the expiry time
that is provided by the client. The provided expiry time of the client is
updated after inserting the astdb entry. As a consequence, restarting or
reloading asterisk creates clients whose registration may expire before
they reregister. The clients are therefore unavailable after minregexpire
seconds until they reregister.
* Move updating of the expiry time to before inserting into the astdb.
(closes issue ASTERISK-22504)
Reported by: Stefan Wachtler
Patches:
chan_iax2.c.patch (license #6533) patch uploaded by Stefan Wachtler
........
Merged revisions 399158 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399159 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399160 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399161
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Mon, 16 Sep 2013 02:37:56 +0000 (02:37 +0000)]
Filter internal channels out of bridge enter/leave message handling
Some channels exist merely as an implementation detail in Asterisk, such as
ConfBridge's announcer/recorder channels. These channels should never be
exposed to the outside world, or to interfaces that report on Asterisk. We
already filter out such channels in snapshot processing; however, we failed to
filter out bridge related messages that involved these channels.
This patch filters out bridge related messages that are for such channels. This
prevents a spurious WARNING message from being displayed when those channels
move in and out of bridges.
........
Merged revisions 399146 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399147
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Fri, 13 Sep 2013 22:19:23 +0000 (22:19 +0000)]
Restore Dial, Queue, and FollowMe 'I' option support.
The Dial, Queue, and FollowMe applications need to inhibit the bridging
initial connected line exchange in order to support the 'I' option.
* Replaced the pass_reference flag on ast_bridge_join() with a flags
parameter to pass other flags defined by enum ast_bridge_join_flags.
* Replaced the independent flag on ast_bridge_impart() with a flags
parameter to pass other flags defined by enum ast_bridge_impart_flags.
* Since the Dial, Queue, and FollowMe applications are now the only
callers of ast_bridge_call() and ast_bridge_call_with_flags(), changed the
calling contract to require the initial COLP exchange to already have been
done by the caller.
* Made all callers of ast_bridge_impart() check the return value. It is
important. As a precaution, I also made the compiler complain now if it
is not checked.
* Did some cleanup in parking_tests.c as a result of checking the
ast_bridge_impart() return value.
An independent, but associated change is:
* Reduce stack usage in ast_indicate_data() and add a dropping redundant
connected line verbose message.
(closes issue ASTERISK-22072)
Reported by: Joshua Colp
Review: https://reviewboard.asterisk.org/r/2845/
........
Merged revisions 399136 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399138
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Fri, 13 Sep 2013 20:55:09 +0000 (20:55 +0000)]
Don't write to /tmp/refs when REF_DEBUG is not defined.
If MALLOC_DEBUG is enabled, then the debug destructor for the container
is used, which would erroneously write to /tmp/refs. This patch only
uses the debug destructor if ref_debug is used.
(closes issue ASTERISK-22536)
........
Merged revisions 399098 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399099 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399100 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399101
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Fri, 13 Sep 2013 14:50:38 +0000 (14:50 +0000)]
Create more accurate Contact headers for dialogs when we are the UAS.
(closes issue AST-1207)
reported by John Bigelow
Review: https://reviewboard.asterisk.org/r/2842
........
Merged revisions 399083 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399084
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Fri, 13 Sep 2013 14:44:43 +0000 (14:44 +0000)]
Change how realms are handled for outbound authentication.
With this change, if no realm is specified in an outbound auth
section, then we will simply match the realm that was present
in the 401/407 challenge.
(closes issue ASTERISK-22471)
Reported by George Joseph
(closes issue ASTERISK-22386)
Reported by Rusty Newton
Patches:
outbound_auth_realm_v4.patch uploaded by George Joseph (License #6322)
........
Merged revisions 399059 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399082
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Fri, 13 Sep 2013 14:43:56 +0000 (14:43 +0000)]
Recorded merge of revisions 399035,399049 from svn.asterisk.org/svn/asterisk/branches/12
These were lost in r399071
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399081
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Fri, 13 Sep 2013 14:34:43 +0000 (14:34 +0000)]
Put merge tracking for r399039 back.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399080
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Fri, 13 Sep 2013 14:27:54 +0000 (14:27 +0000)]
Broke the build! Forgot para tags within my description.
https://bamboo.asterisk.org/bamboo/browse/AST-ATRUNKBUILD-304
........
Merged revisions 399064 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399071
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Fri, 13 Sep 2013 14:22:07 +0000 (14:22 +0000)]
res_pjsip: Forward PJSIP logging to Asterisk logging
This patch uses PJSIP's pj_log_set_log_func() to forward PJSIP's log
messages to Asterisk's logger. This is done in a new module:
res_pjsip_log_forwarder.so.
This patch sets defaultenabled on the existing res_pjsip_logger.so to
no, since logging every SIP packet seems a bit odd to do by default, and
is (hopefully) less necessary with regular PJSIP logging.
It also removes res_rtp_asterisk's disabling of PJSIP logging.
(closes issue ASTERISK-22360)
Reported by: Joshua Colp
Review: https://reviewboard.asterisk.org/r/2830/
........
Merged revisions 399049 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399051
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Fri, 13 Sep 2013 14:19:19 +0000 (14:19 +0000)]
ARI: Fix WebSocket response when subprotocol isn't specified
When I moved the ARI WebSocket from /ws to /ari/events, I added code to
allow a WebSocket to connect without specifying the subprotocol if
there's only one subprotocol handler registered for the WebSocket.
Naively, I coded it to always respond with the subprotocol in use.
Unfortunately, according to RFC 6455, if the server's response includes
a subprotocol header field that "indicates the use of a subprotocol that
was not present in the client's handshake [...], the client MUST _Fail
the WebSocket Connection_.", emphasis theirs.
This patch correctly omits the Sec-WebSocket-Protocol if one is not
specified by the client.
(closes issue ASTERISK-22441)
Review: https://reviewboard.asterisk.org/r/2828/
........
Merged revisions 399039 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399042
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kinsey Moore [Fri, 13 Sep 2013 14:17:15 +0000 (14:17 +0000)]
Fix several crashes in MeetMeAdmin
This change ensures that MeetMeAdmin commands requiring a user actually
get a user and fixes another issue where an extra dereference could
occur for a last-entered user being ejected if a user identifier was
also provided.
(closes issue ASTERISK-21907)
Reported by: Alex Epshteyn
Review: https://reviewboard.asterisk.org/r/2844/
........
Merged revisions 399033 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 399034 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 399035 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399036
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Fri, 13 Sep 2013 13:28:26 +0000 (13:28 +0000)]
'identify' configObject doesn't have a synopsis
Add a straightforward synopsis and description to the identify config object
in XML documentation.
(issue ASTERISK-22311)
(closes issue ASTERISK-22311)
Reported By: Rusty Newton
........
Merged revisions 399031 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399032
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Thu, 12 Sep 2013 23:42:23 +0000 (23:42 +0000)]
CLI bridge: Fix "bridge destroy <id>" and "bridge kick <id> <chan>" tab completion.
These two commands must deal with the live bridges container for tab
completion and not the stasis cache.
........
Merged revisions 399021 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399022
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Thu, 12 Sep 2013 23:36:33 +0000 (23:36 +0000)]
astobj2: Register the bridges container for debug inspection.
........
Merged revisions 399019 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399020
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Thu, 12 Sep 2013 23:23:12 +0000 (23:23 +0000)]
Documentation fix and improvements to XML configuration help res_pjsip_acl
* One bug fix. Made the synopsis for "type" to accurate.
* changing the usage of "IP-domains" to "IP addresses"
* clarifying the usage for the options, by adding a relevant description for
each
* modified other areas of the XML help for clarity, such as the module
description and a few synopsis changes here and there. See the patch.
(issue ASTERISK-22458)
(closes issue ASTERISK-22458)
Reported By: Rusty Newton
Review: https://reviewboard.asterisk.org/r/2823/
........
Merged revisions 399017 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399018
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Thu, 12 Sep 2013 20:27:56 +0000 (20:27 +0000)]
chan_sip: Revert r398835 due to failing tests involving originate
(issue ASTERISK-22424)
Reported by: Jonathan Rose
........
Merged revisions 398977 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398986 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398991 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@399006
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Thu, 12 Sep 2013 16:44:34 +0000 (16:44 +0000)]
core_local: Fix memory corruption race condition.
The masquerade super test is failing on v12 with high fence violations and
crashing. The fence violations are showing that party id allocated memory
strings are somehow getting corrupted in the
bridge_reconfigured_connected_line_update() function. The invalid string
values happen to be the freed memory fill pattern.
After much puzzling, I deduced that the
bridge_reconfigured_connected_line_update() is copying a string out of the
source channel's caller party id struct just as another thread is updating
it with a new value. The copying thread is using the old string pointer
being freed by the updating thread. A search of the code found the
unreal_colp_redirect_indicate() routine updating the caller party id's
without holding the channel lock.
A latent bug in v1.8 and v11 hatched in v12 because of the bridging and
connected line changes. :)
(issue ASTERISK-22221)
Reported by: Matt Jordan
Review: https://reviewboard.asterisk.org/r/2839/
........
Merged revisions 398938 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398939
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Thu, 12 Sep 2013 15:23:54 +0000 (15:23 +0000)]
Fix symbol collision with pjsua.
We shouldn't be exporting any symbols that start with pjsip_.
........
Merged revisions 398927 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398928
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Thu, 12 Sep 2013 00:04:57 +0000 (00:04 +0000)]
'queue add member' help text correction
You are adding dial strings to the queue, not channels. An aribitrary string
could be used, but you are typically referencing a channel. Correcting the
command help text.
(issue ASTERISK-22263)
(closes issue ASTERISK-22263)
Reported By: Rusty Newton
........
Merged revisions 398884 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398885 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398886 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398887
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Rusty Newton [Wed, 11 Sep 2013 23:52:49 +0000 (23:52 +0000)]
Documentation fix - waitfordialtone is not boolean, it's time in milliseconds
Changing text in chan_dahdi.conf sample to be accurate.
(issue ASTERISK-22308)
(closes issue ASTERISK-22308)
Reported By: Malcolm Davenport
........
Merged revisions 398880 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398881 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398882 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398883
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Jonathan Rose [Wed, 11 Sep 2013 20:03:19 +0000 (20:03 +0000)]
chan_sip: Reject calls without prior SDP on 200 OK
If we receive a 200 OK without SDP, we will now check to see if
the remote address has been established for that channel's RTP
session and if the to tag for that channel has changed from
the most recent to tag in a response less than 200.
If either a change has been made since the last to-tag was
received or the remote address is unset, then we will drop
the call.
(closes issue ASTERISK-22424)
Reported by: Jonathan Rose
Review: https://reviewboard.asterisk.org/r/2827/diff/#index_header
........
Merged revisions 398835 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398836 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398837 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398838
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Russell Bryant [Wed, 11 Sep 2013 18:03:30 +0000 (18:03 +0000)]
Fix typo in confbridge.conf.sample
The denoise filter requires func_speex, not codec_speex. Fix this in the
description of the denoise=yes option in confbridge.conf.
........
Merged revisions 398820 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398821 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398822
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Kevin Harwell [Wed, 11 Sep 2013 14:23:28 +0000 (14:23 +0000)]
pjsip: reinvite for connected line updates occurs when it should not
Connected line updates are now only sent out if an actual update needs to occur.
This happens under the following conditions:
1. The endpoint we are sending to is trusted.
2. Either a P-Asserted-Identity or Remote Party-ID header needs to be added/sent.
3. The connected id's number and name are valid.
Also added an SDP when an update is sent out.
(closes issue AST-1212)
Reported by: John Bigelow
Review: https://reviewboard.asterisk.org/r/2831/
........
Merged revisions 398806 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398808
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Tue, 10 Sep 2013 18:05:47 +0000 (18:05 +0000)]
Fix incorrect usages of ast_realloc().
There are several locations in the code base where this is done:
buf = ast_realloc(buf, new_size);
This is going to leak the original buf contents if the realloc fails.
Review: https://reviewboard.asterisk.org/r/2832/
........
Merged revisions 398757 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398758 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398759 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398760
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Tue, 10 Sep 2013 17:50:13 +0000 (17:50 +0000)]
Fixed utils directory breakage from r398748, this time with extra hate.
........
Merged revisions 398752 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398753 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398754 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398755
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Tue, 10 Sep 2013 17:26:19 +0000 (17:26 +0000)]
Fixed utils directory breakage from r398648
........
Merged revisions 398748 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398749 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398750 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398751
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Richard Mudgett [Mon, 9 Sep 2013 23:29:44 +0000 (23:29 +0000)]
MALLOC_DEBUG: Change fence magic number to be completely different from the freed magic number.
Race conditions between freeing a nul terminated string and
ast_strdup()'ing it are more likely to be detected if the fence and freed
magic numbers are completely different.
........
Merged revisions 398703 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398721 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398726 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398732
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Mark Michelson [Mon, 9 Sep 2013 22:00:44 +0000 (22:00 +0000)]
Add extra debugging to res_pjsip_endpoint_identifier_ip
........
Merged revisions 398694 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398695
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Mon, 9 Sep 2013 20:13:40 +0000 (20:13 +0000)]
Fix DEBUG_THREADS when lock is acquired in __constructor__
This patch fixes some long-standing bugs in debug threads that were
exacerbated with recent Optional API work in Asterisk 12.
With debug threads enabled, on some systems, there's a lock ordering
problem between our mutex and glibc's mutex protecting its module list
(Ubuntu Lucid, glibc 2.11.1 in this instance). In one thread, the module
list will be locked before acquiring our mutex. In another thread, our
mutex will be locked before locking the module list (which happens in
the depths of calling backtrace()).
This patch fixes this issue by moving backtrace() calls outside of
critical sections that have the mutex acquired. The bigger change was to
reentrancy tracking for ast_cond_{timed,}wait, which wrongly assumed
that waiting on the mutex was equivalent to a single unlock (it actually
suspends all recursive locks on the mutex).
(closes issue ASTERISK-22455)
Review: https://reviewboard.asterisk.org/r/2824/
........
Merged revisions 398648 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 398649 from http://svn.asterisk.org/svn/asterisk/branches/11
........
Merged revisions 398651 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398652
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Mon, 9 Sep 2013 19:09:21 +0000 (19:09 +0000)]
Multiple revisions 398638-398639
........
r398638 | dlee | 2013-09-09 14:01:54 -0500 (Mon, 09 Sep 2013) | 1 line
Added note about expected behavior of originate
........
r398639 | dlee | 2013-09-09 14:02:27 -0500 (Mon, 09 Sep 2013) | 1 line
Added note about expected behavior of originate (the rest of the commit)
........
Merged revisions 398638-398639 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398641
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
David M. Lee [Mon, 9 Sep 2013 19:08:15 +0000 (19:08 +0000)]
Blocked revisions 398559,398578
........
Multiple revisions 398559,398578
........
r398559 | kmoore | 2013-09-06 14:32:03 -0500 (Fri, 06 Sep 2013) | 20 lines
Blocked revisions 398558
........
Fix Jabber/XMPP distributed MWI
The mailbox and context are swapped on the receiving end for all users
of Jabber and XMPP distributed MWI in Asterisk 1.8 and all more recent
versions. This swaps those values to be correct when publishing to the
internal event system from Jabber/XMPP distributed MWI state.
(closes issue ASTERISK-22435)
Reported by: abelbeck
Tested by: Michael Keuter
Patches:
asterisk-1.8-res_jabber-aji_handle_pubsub_event.patch uploaded by abelbeck
asterisk-11-res_xmpp-xmpp_pubsub_handle_event.patch uploaded by abelbeck
........
Merged revisions 398523 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
r398578 | kmoore | 2013-09-06 16:03:45 -0500 (Fri, 06 Sep 2013) | 1 line
Unblock r398558
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398640
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
Matthew Jordan [Sun, 8 Sep 2013 23:30:39 +0000 (23:30 +0000)]
Update CDR Unit tests to reflect container changes in r398579
When a channel joins a multi-party bridge, the ordering of the CDRs that is
created is determined by the ordering of the channels who happen to be in that
bridge. When r398579 changed the number of buckets in the container to
something sensible, it changed the ordering that the CDRs was created in,
causing one of the multiparty tests to fail. This fixes the test with the
now expected ordering.
........
Merged revisions 398628 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@398629
65c4cc65-6c06-0410-ace0-
fbb531ad65f3