Commit Graph

3986 Commits

Author SHA1 Message Date
Richard Mudgett 5f740572d0 Fix compiler warning.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390734 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06 20:50:25 +00:00
Richard Mudgett 5c554dc470 * Fix a couple missed hook installs that need AST_BRIDGE_HOOK_REMOVE_ON_PULL.
* Rename some hook flag parameters to remove_flags.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390733 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06 20:47:10 +00:00
Jason Parker 9f54568010 Convert message_router routes to ao2. Add support for removal.
Review: https://reviewboard.asterisk.org/r/2591/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390698 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06 19:44:45 +00:00
Jonathan Rose c57a2735d8 Parking: Enable code responsible for intercepting park exten transfers
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06 18:21:18 +00:00
Richard Mudgett 6bb88d2e80 Misc core external attended transfer fixes.
* Fix external attended transfer bridge move/swap method.  One of the
transferrer channels was not kicked out of the bridge.

* Fix several off-nominal extended attended transfer paths.  Mainly the
channels involved needed to be hung up or kicked out of the bridge.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390613 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-06 00:16:23 +00:00
Richard Mudgett e7e7d7759b Make local channels use ast_channel_move() instead of the inlined version.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390612 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 23:29:43 +00:00
David M. Lee a36d38ab38 Fixed refcounting problems with chanspy AMI support.
The ast_multi_channel_blob_get_channel function does not bump the refcount on
the channel snapshot that it returns. This is typical for Stasis message
payloads, since being immutable means that the object won't get unreffed out
from underneath you.

The manager code for chanspy was unreffing the snapshots it got out of the
multi-channel blob, which was one unref too many.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390584 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 21:14:03 +00:00
Mark Michelson 94d8d0468f Remove remaining traces of remove_on_pull from hooks and hook APIs.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390550 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 19:19:48 +00:00
Mark Michelson 4789c3fb0c Change the remove_on_pull flag on ast_bridge_hook to be a set of flags.
This change is used to make bridge hook removal more generic. This way,
depending on the circumstance, the appropriate bridge hooks may be
removed.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390510 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 18:07:23 +00:00
Joshua Colp fb6344e249 Publish the channel state snapshot *before* calling device state so a device state producer can use
an up to date snapshot.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390473 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 14:50:46 +00:00
David M. Lee f574a76e3e Fixed a consistency problem with channel snapshot and endpoint state.
When channels are added to an endpoint, the code originally posted a channel
snapshot to the endoint's topic directly. Turns out, this is a bad idea.

This causes the endpoint to see an inconsistent view of the channel, since it
will later receive in-flight messages with old channel snapshots.

This patch instead just publishes channel state immediately after setting up
the forward to the endpoint's topic. This gives the endpoints a consistent
view of the channel's state.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390472 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-05 14:47:30 +00:00
David M. Lee 6d805dc04b Correct autoconf script for finding UUID support.
The library that provides UUID support varies greatly from system to
system. On most Linux distros, it's in libuuid. On OpenBSD, it's in
libe2fs-uuid. On OS X, it is in libsystem.

This patch plays hide-and-seek with UUID support, looking for it in the
three places we know about. It also corrects the Makefile so that it uses
the configured library name and include path.

(closes issue ASTERISK-21816)
Reported by: Brad Latus (snuffy)
Tested by: Brad Latus (snuffy)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390352 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-03 15:57:42 +00:00
Kinsey Moore 1458a20e47 Refactor code and fix a reference leak
Refactor some channel blob publishing code to use
ast_channel_publish_blob now that it is available and fix a JSON
reference leak that was occurring during varset publishing.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390317 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 19:00:51 +00:00
Richard Mudgett 680765d452 Remove ast_channel_bridge() and associated code called only by it.
* Added some more BUGBUG notes.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390291 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 16:15:32 +00:00
Richard Mudgett ccc8cc5346 Fixup hold/unhold with attended and blind transfers.
* DTMF attended and blind transfers have hold/unhold behavior restored.

* External attended and blind transfers unhold the transfered party when
the transfer is initiated.

* Made prohibit blind transferring a bridge marked as masquerade only.
(ConfBridge bridges)

* Made running an application or playing a file inside a bridge post the
hold/unhold messages if MOH is requested.

Review: https://reviewboard.asterisk.org/r/2574/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390289 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 15:34:20 +00:00
Jason Parker a1494300c9 Replace ast_manager_publish_message() with a more useful version.
It's much easier to just create a blob of the message.  Convert some AMI events
to use it.

Review: https://reviewboard.asterisk.org/r/2577/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390268 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 14:36:08 +00:00
Kinsey Moore 39d5e40cd5 Remove remnant of snapshot blob JSON types
Remove usage of the once-mandatory snapshot blob type field, refactor
confbridge stasis messages accordingly, and remove
ast_bridge_blob_json_type().

Review: https://reviewboard.asterisk.org/r/2575/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390250 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 12:41:10 +00:00
Kinsey Moore e1bff7958a Add snapshot cache that indexes by channel name
This adds a new channel snapshot cache in parallel to the existing
cache; the difference being that it indexes the channel snapshots by
channel name instead of channel uniqueid.

Review: https://reviewboard.asterisk.org/r/2576


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390249 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 12:27:29 +00:00
David M. Lee 721a1faf6d Missed a line from a bad merge in r390122
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390154 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-30 19:23:53 +00:00
David M. Lee d81c846724 Avoid unnecessary cleanups during immediate shutdown
This patch addresses issues during immediate shutdowns, where modules
are not unloaded, but Asterisk atexit handlers are run.

In the typical case, this usually isn't a big deal. But the
introduction of the Stasis message bus makes it much more likely for
asynchronous activity to be happening off in some thread during
shutdown.

During an immediate shutdown, Asterisk skips unloading modules. But
while it is processing the atexit handlers, there is a window of time
where some of the core message types have been cleaned up, but the
message bus is still running. Specifically, it's still running
module subscriptions that might be using the core message types. If a
message is received by that subscription in that window, it will
attempt to use a message type that has been cleaned up.

To solve this problem, this patch introduces ast_register_cleanup().
This function operates identically to ast_register_atexit(), except
that cleanup calls are not invoked on an immediate shutdown. All of
the core message type and topic cleanup was moved from atexit handlers
to cleanup handlers.

This ensures that core type and topic cleanup only happens if the
modules that used them are first unloaded.

This patch also changes the ast_assert() when accessing a cleaned up
or uninitialized message type to an error log message. Message type
functions are actually NULL safe across the board, so the assert was a
bit heavy handed. Especially for anyone with DO_CRASH enabled.

Review: https://reviewboard.asterisk.org/r/2562/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390122 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-30 17:05:53 +00:00
Richard Mudgett f069ee9681 Fix segfault when dealing with chan_agent channels.
Check the returned bridged pointer for NULL to avoid a crash.  It looks
like chan_agent is returning a NULL pointer when it probably should be
returning a pointer to the channel the Agent channel is pretending to be.

(closes issue ASTERISK-21793)
Reported by: Rodrigo P. Telles
Patches:
      jira_asterisk_21793_v1.8.patch (license #5621) patch uploaded by rmudgett
Tested by: Rodrigo P. Telles
........

Merged revisions 390044 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 390047 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390068 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-29 20:24:18 +00:00
Jason Parker fa98eb2aea Remove unused RAII vars.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390042 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-29 19:54:01 +00:00
Kinsey Moore 6851801a5e Resolve a merge conflict
When ast_channel_cached_blob_create was merged,
ast_channel_blob_create_from_cache was partially removed in an
unresolved merge conflict. This restores ast_channel_blob_create_from_cache
and refactors usage of ast_channel_cached_blob_create (requires an
ast_channel) to use ast_channel_blob_create_from_cache (requires a
channel uniqueid) instead.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389974 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-29 02:26:17 +00:00
Jonathan Rose bb584c55de Fix a memory copying bug in slinfactory which was causing mixmonitor issues.
Reported by: Michael Walton
Tested by: Jonathan Rose
Patches:
    slinfactory.c.ASTERISK-21799.patch uploaded by Michael Walton (license 6502)
(closes issue ASTERISK-21799)
........

Merged revisions 389895 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 389896 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389897 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-28 17:47:29 +00:00
Mark Michelson 45dc10de84 Add missing NULL check to acquire_bridge() function.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389870 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-28 15:54:53 +00:00
Mark Michelson fac3839e68 Adds support for a core attended transfer function plus adds some hiding of masquerades.
The attended transfer API call can complete the attended transfer in a number of ways
depending on the current bridged states of the channels involved.

The hiding of masquerades is done in some bridging-related functions, such as the manager
Bridge action and the Bridge dialplan application. In addition, call pickup was edited
to "move" a channel rather than masquerade it.

Review: https://reviewboard.asterisk.org/r/2511

(closes issue ASTERISK-21334)
Reported by Matt Jordan

(closes issue Asterisk-21336)
Reported by Matt Jordan



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389848 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-28 14:45:31 +00:00
Matthew Jordan a0f6d1848b Initialize the message type before the topic
Caching topics will during initialization attempt to reference
their message type. The message type therefore has to be
initialized prior to the topic to prevent the dreaded assertion.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389813 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-27 00:06:40 +00:00
Matthew Jordan fe3ca5401f Fix a variety of memory corruption/assertion errors
* Initialize a Stasis-Core message type prior to initializing a caching topic.
  The caching topic will attempt to use the message type.
* Don't attempt to publish Stasis-Core messages from remote console connections.
  They aren't the main process; they shouldn't attempt to behave as it (they also
  don't have the infrastructure to do so)
* Don't treat a JSON object as an ao2 object (whoops)
* In asterisk.c, ref bump the JSON even package that is distributed with the
  event meta data. The callers assume that they own the reference, and the packing
  routine steals references.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389785 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-26 04:47:17 +00:00
Matthew Jordan 97c6062dfc Restore initialization of security topics
During a merge the security topic initialization got blown away.
This patch restores it.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389770 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-25 17:41:25 +00:00
Jason Parker 154fbf8cae Split Hold event into Hold/Unhold, and move it into core.
(closes issue ASTERISK-21487)
Review: https://reviewboard.asterisk.org/r/2565/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389746 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-24 21:21:25 +00:00
Matthew Jordan 06be8463b6 Migrate a large number of AMI events over to Stasis-Core
This patch moves a number of AMI events over to the Stasis-Core message bus.
This includes:
 * ChanSpyStart/Stop
 * MonitorStart/Stop
 * MusicOnHoldStart/Stop
 * FullyBooted/Reload
 * All Voicemail/MWI related events

In addition, it adds some Stasis-Core and AMI support for generic AMI messages,
refactors the message router in AMI to use a single router with topic
forwarding for the topics that AMI cares about, and refactors MWI message
types and topics to be more name compliant.

Review: https://reviewboard.asterisk.org/r/2532

(closes issue ASTERISK-21462)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389733 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-24 20:44:07 +00:00
Matthew Jordan c1b51fd265 Print all logger messages on shutdown
When Asterisk shuts down and shuts down the loggin gsubsystem, any
messages currently in flight will not get logged. This patch prevents the
loop writing messages from breaking out prematurely, such that all of the
messages are logged.

(closes issue ASTERISK-21716)
Reported by: Corey Farrell
patches:
  logger-process-all-messages.patch uploaded by Corey Farrell (license 5909)
........

Merged revisions 389676 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 389677 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389680 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-24 11:57:48 +00:00
David M. Lee 557125664d This patch adds support for controlling a playback operation from the
Asterisk REST interface.

This adds the /playback/{playbackId}/control resource, which may be
POSTed to to pause, unpause, reverse, forward or restart the media
playback.

Attempts to control a playback that is not currently playing will
either return a 404 Not Found (because the playback object no longer
exists) or a 409 Conflict (because the playback object is still in the
queue to be played).

This patch also adds skipms and offsetms parameters to the
/channels/{channelId}/play resource.

(closes issue ASTERISK-21587)
Review: https://reviewboard.asterisk.org/r/2559


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389603 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-23 20:21:16 +00:00
David M. Lee 10ba6bf8a8 This patch implements the REST API's for POST /channels/{channelId}/play
and GET /playback/{playbackId}.

This allows an external application to initiate playback of a sound on a
channel while the channel is in the Stasis application.

/play commands are issued asynchronously, and return immediately with
the URL of the associated /playback resource. Playback commands queue up,
playing in succession. The /playback resource shows the state of a
playback operation as enqueued, playing or complete. (Although the
operation will only be in the 'complete' state for a very short time,
since it is almost immediately freed up).

(closes issue ASTERISK-21283)
(closes issue ASTERISK-21586)
Review: https://reviewboard.asterisk.org/r/2531/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389587 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-23 20:11:35 +00:00
Richard Mudgett 3464e0919a Fix inverted test preventing DTMF disconnect from working.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389569 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-23 18:40:50 +00:00
David M. Lee 8a5a09e62c Fixed startup race condition which caused occasional stasis_mwi_state_type assertions.
The caching topic (which refers to the message type) was created before the
message type. If the initial subscription message gets processed before
the type can be initialized, the assertion about using an uninitialized type
fires.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389519 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-22 19:15:16 +00:00
Jason Parker b6aac885be Add dial events to app_queue and app_followme.
Also fixes an issue in app_dial, where the channels were swapped on dial events.

(closes issue ASTERISK-21551)
(closes issue ASTERISK-21550)

Review: https://reviewboard.asterisk.org/r/2549/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389492 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-22 18:11:57 +00:00
David M. Lee 054efbc45a Fix destruction order assert for stasis_bridging
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389454 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-21 22:49:23 +00:00
Richard Mudgett 3d63833bd6 Merge in the bridge_construction branch to make the system use the Bridging API.
Breaks many things until they can be reworked.  A partial list:
chan_agent
chan_dahdi, chan_misdn, chan_iax2 native bridging
app_queue
COLP updates
DTMF attended transfers
Protocol attended transfers


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389378 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-21 18:00:22 +00:00
David M. Lee e1e1cc2dee Fixed some extra field assertion when the event WebSocket is connected
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389343 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-21 14:17:24 +00:00
Matthew Jordan d8aec72494 Set the AST_CDR_FLAG_ORIGINATED flag on originated channel's CDRs
This may alleviate some of the CDR woes with originated channels, as CDRs
do like to know when a channel was originated. Eventually this will get
converted to be a channel flag, so its location is still good to know
post the great CDR shakeup of 2013.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389306 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-20 19:24:16 +00:00
Joshua Colp 734a154eef In Sorcery pass the name of the object being allocated to the allocator.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389204 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-20 14:02:37 +00:00
Joshua Colp b46840ae3e Don't hold the outgoing lock for a prolonged period of time as it may block the originator.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389132 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-19 02:21:44 +00:00
Joshua Colp 4d8c35abf2 If the caller of the originate API calls wants the channel ensure it has been requested and dialed.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389116 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-19 00:49:15 +00:00
Joshua Colp 7316abeb8f Fix a bug where synchronous origination (oddly enough triggered by doing an async manager Originate) would not work properly.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389085 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-18 22:49:14 +00:00
Joshua Colp 4e38a4eb64 Move origination to use the dialing API and send Stasis messages on dial begin and end.
(closes issue ASTERISK-21549)
Reported by: Matt Jordan

Review: https://reviewboard.asterisk.org/r/2512/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389053 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-18 19:47:24 +00:00
David M. Lee b97c71bb11 Fix shutdown assertions in stasis-core
In r388005, macros were introduced to consistently define message
types. This added an assert if a message type was used either before
it was initialized or after it had been cleaned up. It turns out that
this assertion fires during shutdown.

This actually exposed a hidden shutdown ordering problem. Since
unsubscribing is asynchronous, it's possible that the message types
used by the subscription could be freed before the final message of
the subscription was processed.

This patch adds stasis_subscription_join(), which blocks until the
last message has been processed by the subscription. Since joining was
most commonly done right after an unsubscribe, a
stasis_unsubscribe_and_join() convenience function was also added.

Similar functions were also added to the stasis_caching_topic and
stasis_message_router, since they wrap subscriptions and have similar
problems.

Other code in trunk was refactored to join() where appropriate, or at
least verify that the subscription was complete before being
destroyed.

Review: https://reviewboard.asterisk.org/r/2540


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389011 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-17 21:10:32 +00:00
Matthew Jordan d04f1fd60a Publish the outbound channel's application/data when dialing
This patch does two things:
* It fixes a bug where the outbound channel's application/data set by the
  dialing API/app_dial is not communicated until the channel is hung up.
  If that happens, AMI would incorrectly send a NewExten event immediately
  after a Hangup. This isn't really AMI's fault, as the dialing APIs never
  communicated the 'helpful' app/data on the outbound channel until it was
  hungup.
* It makes public sending a stasis message about a change in channel state.
  This is useful enough that - for now at least - it should be public. If
  operations on a channel go to being more coarse-grained, this function
  could be made private again.

Review: https://reviewboard.asterisk.org/r/2548

Note that this problem was found and reported by Matt DiMeo.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@388976 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-17 17:43:58 +00:00
Jonathan Rose b90bba7a30 Stasis: Update security events to use Stasis
Also moves ACL messages to the security topic and gets rid of the
ACL topic

(closes issue ASTERISK-21103)
Reported by: Matt Jordan
Review: https://reviewboard.asterisk.org/r/2496/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@388975 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-17 17:36:10 +00:00
Kevin Harwell 2eebab3992 Fix for segfault in __ast_rwlock_destroy with DEBUG_THREADS
If DEBUG_THREADS is enabled __ast_rwlock_destroy causes a segfault while trying
to access a possible NULL t->track object.  A NULL check has been added before
trying to access the memory.

(closes issue ASTERISK-21724)
Reported by: Corey Farrell
Fixed by: Corey Farrell
Patches:
	ast_rwlock_destroy-segv.patch uploaded by Corey Farrell (license 5909)
........

Merged revisions 388838 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 388839 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@388840 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-15 15:58:56 +00:00