]> git.ipfire.org Git - thirdparty/asterisk.git/log
thirdparty/asterisk.git
10 years agoendpoint/stasis: Eliminate duplicate events on endpoint status change 41/541/3
George Joseph [Wed, 27 May 2015 18:22:39 +0000 (12:22 -0600)] 
endpoint/stasis: Eliminate duplicate events on endpoint status change

When an endpoint was created, it's messages were being forwarded to
both the tech endpoint topic and the all endpoints topic.  Since
the tech topic was also forwarded to all, this was resulting in
duplicate messages whenever an endpoint published.  This patch
causes the endpoint to only forward to the tech topic and lets
the tech topic forward to all.

To accomplish this, the existing stasis_cp_single_create function
(which both creates and forwards) was cloned and split into 2
functions, one that creates the topic and one that sets up the
forwarding.  This allows endpoint_internal_create to create
the topic from the endpoint_all cache without forwarding it there,
then allows it to do the forward to the tech's topic.

ASTERISK-25137 #close
Reported-by: Vitezslav Novy
ASTERISK-25116 #close
Reported-by: George Joseph <george.joseph@fairview5.com>
Tested-by: George Joseph <george.joseph@fairview5.com>
Change-Id: I26d7d4926a0861748fd3bdffe316b75b549a801c

10 years agores_pjsip: Add AMI events for chan_pjsip contact lifecycle changes 18/518/4
George Joseph [Thu, 21 May 2015 22:21:01 +0000 (16:21 -0600)] 
res_pjsip: Add AMI events for chan_pjsip contact lifecycle changes

Add a new ContactStatus AMI event.
Publish the following status/state changes:
Created
Removed
Reachable
Unreachable
Unknown

Contact URI, new status/state, aor and endpoint names, and the
last qualify rtt result are included in the event.

ASTERISK-25114 #close

Change-Id: Id25aae5f7122facba183273efb3e8f36c20fb61e
Reported-by: George Joseph <george.joseph@fairview5.com>
Tested-by: George Joseph <george.joseph@fairview5.com>
10 years agoMerge "Astobj2: Correctly treat hash_fn returning INT_MIN" into 13
Joshua Colp [Tue, 26 May 2015 21:07:13 +0000 (16:07 -0500)] 
Merge "Astobj2: Correctly treat hash_fn returning INT_MIN" into 13

10 years agosorcery: Fix cache creation callback. 33/533/1
Joshua Colp [Tue, 26 May 2015 12:44:18 +0000 (09:44 -0300)] 
sorcery: Fix cache creation callback.

The cache creation callback function expects to receive a sorcery_details
structure and not just a standalone object.

Change-Id: I3e4a5a137cb25292eb52d7a14cbb6daa09213450

10 years agoAstobj2: Correctly treat hash_fn returning INT_MIN 31/531/4
Ivan Poddubny [Sun, 24 May 2015 18:47:16 +0000 (21:47 +0300)] 
Astobj2: Correctly treat hash_fn returning INT_MIN

The code in astobj2_hash.c wrongly assumed that abs(int) is always > 0.
However, abs(INT_MIN) = INT_MIN and is still negative, as well as
abs(INT_MIN) % num_buckets, and as a result this led to a crash.

One way to trigger the bug is using host=::80 or 0.0.0.128 in peer
configuration section in chan_sip or chan_iax.

This patch takes the remainder before applying abs, so that bucket
number is always in range.

ASTERISK-25100 #close
Reported by: Mark Petersen

Change-Id: Id6981400ad526f47e10bcf7b847b62bd2785e899

10 years agoMerge "Stasis: Fix unsafe use of stasis_unsubscribe in modules." into 13
Matt Jordan [Sun, 24 May 2015 18:56:12 +0000 (13:56 -0500)] 
Merge "Stasis: Fix unsafe use of stasis_unsubscribe in modules." into 13

10 years agores_pjsip_transport_websocket: Fix crash on receiving large SIP packets 29/529/1
Ivan Poddubny [Sat, 23 May 2015 09:36:18 +0000 (12:36 +0300)] 
res_pjsip_transport_websocket: Fix crash on receiving large SIP packets

Incoming SIP packets larger than PJSIP_MAX_PKT_LEN were themselves
truncated before passing to pjsip_tpmgr_receive_packet, but the length
was passed unaltered, thus causing memory corruption and segfault.

ASTERISK-25122 #close

Change-Id: I608a6b6b7f229eacc33a0a7d771d18e27e5b08ab

10 years agoStasis: Fix unsafe use of stasis_unsubscribe in modules. 26/526/1
Corey Farrell [Sat, 23 May 2015 02:50:43 +0000 (22:50 -0400)] 
Stasis: Fix unsafe use of stasis_unsubscribe in modules.

Many uses of stasis_unsubscribe in modules can be reached through unload.
These have been switched to stasis_unsubscribe_and_join.

Some subscription callbacks do nothing, for these I've created a noop
callback function in stasis.c.  This is used by some modules that monitor
MWI topics in order to enable cache, since the callback does not become
invalid after dlclose it is safe to use stasis_unsubscribe on these, even
during module unload.

ASTERISK-25121 #close

Change-Id: Ifc2549fbd8eef7d703c222978e8f452e2972189c

10 years agoMerge "res/res_pjsip_pubsub: Note that 'dialog' is also a valid event type for RLS...
Matt Jordan [Fri, 22 May 2015 17:28:18 +0000 (12:28 -0500)] 
Merge "res/res_pjsip_pubsub: Note that 'dialog' is also a valid event type for RLS" into 13

10 years agoMerge "res/res_pjsip_exten_state: Fix confusing NOTICE message" into 13
Matt Jordan [Fri, 22 May 2015 17:25:05 +0000 (12:25 -0500)] 
Merge "res/res_pjsip_exten_state: Fix confusing NOTICE message" into 13

10 years agores/res_pjsip_pubsub: Note that 'dialog' is also a valid event type for RLS 23/523/1
Matt Jordan [Fri, 22 May 2015 17:22:39 +0000 (12:22 -0500)] 
res/res_pjsip_pubsub: Note that 'dialog' is also a valid event type for RLS

In addition to specifying lists of 'presence' and 'message-summary',
users can also create lists of type 'dialog'. These should be treated in
the same fashion as 'presence'.

Change-Id: I583bb69cd9f88b0b29bf09ddaddeac4e84189f6e

10 years agores/res_pjsip_exten_state: Fix confusing NOTICE message 21/521/1
Matt Jordan [Fri, 22 May 2015 17:18:31 +0000 (12:18 -0500)] 
res/res_pjsip_exten_state: Fix confusing NOTICE message

When a SUBSCRIBE request is made to a dialplan hint that doesn't exist,
the current NOTICE message informing users of this swaps the context and
extension parameters. This can cause a bit of confusion.

Thanks to CptBurger in #asterisk for helping to point this out.

Change-Id: Ie584d1a58ae217385c87a450ca25b55ca0e36e43

10 years agoMerge "res/ari: Register Stasis application on WebSocket attempt" into 13
Matt Jordan [Fri, 22 May 2015 16:19:50 +0000 (11:19 -0500)] 
Merge "res/ari: Register Stasis application on WebSocket attempt" into 13

10 years agores/ari: Register Stasis application on WebSocket attempt 86/486/4
Matt Jordan [Mon, 18 May 2015 01:36:41 +0000 (20:36 -0500)] 
res/ari: Register Stasis application on WebSocket attempt

Prior to this patch, when a WebSocket connection is made, ARI would not
be informed of the connection until after the WebSocket layer had
accepted the connection. This created a brief race condition where the
ARI client would be notified that it was connected, a channel would be
sent into the Stasis dialplan application, but ARI would not yet have
registered the Stasis application presented in the HTTP request that
established the WebSocket.

This patch resolves this issue by doing the following:
 * When a WebSocket attempt is made, a callback is made into the ARI
   application layer, which verifies and registers the apps presented in
   the HTTP request. Because we do not yet have a WebSocket, we cannot
   have an event session for the corresponding applications. Some
   defensive checks were thus added to make the application objects
   tolerant to a NULL event session.
 * When a WebSocket connection is made, the registered application is
   updated with the newly created event session that wraps the WebSocket
   connection.

ASTERISK-24988 #close
Reported by: Joshua Colp

Change-Id: Ia5dc60dc2b6bee76cd5aff0f69dd53b36e83f636

10 years agoMerge "res_pjsip: Refactor endpt_send_transaction (qualify_timeout)" into 13
Joshua Colp [Fri, 22 May 2015 15:40:48 +0000 (10:40 -0500)] 
Merge "res_pjsip: Refactor endpt_send_transaction (qualify_timeout)" into 13

10 years agoMerge "res_pjsip_outbound_registration: Check request URI for line." into 13
Matt Jordan [Fri, 22 May 2015 15:38:26 +0000 (10:38 -0500)] 
Merge "res_pjsip_outbound_registration: Check request URI for line." into 13

10 years agores_pjsip: Refactor endpt_send_transaction (qualify_timeout) 92/492/4
George Joseph [Wed, 20 May 2015 16:11:20 +0000 (10:11 -0600)] 
res_pjsip: Refactor endpt_send_transaction (qualify_timeout)

This patch refactors the transaction timeout processing to eliminate
calling the lower level public pjsip functions and reverts to calling
pjsip_endpt_send_request again.  This is the result of me noticing
a possible incompatibility with pjproject-2.4 which was causing
contact status flapping.

The original version of this feature used the lower level calls to
get access to the tsx structure in order to cancel the transaction
when our own timer expires. Since we no longer have that access,
if our own timer expires before the pjsip timer, we call the callbacks
and just let the pjsip transaction take it's own course.  When the
transaction ends, it discovers the callbacks have already been run
and just cleans itself up.

A few messages in pjsip_configuration were also added/cleaned up.

ASTERISK-25105 #close

Change-Id: I0810f3999cf63f3a72607bbecac36af0a957f33e
Reported-by: George Joseph <george.joseph@fairview5.com>
Tested-by: George Joseph <george.joseph@fairview5.com>
10 years agores_pjsip_outbound_registration: Check request URI for line. 82/482/6
demon-ru [Wed, 20 May 2015 05:45:13 +0000 (08:45 +0300)] 
res_pjsip_outbound_registration: Check request URI for line.

When an inbound call is received the To header is checked
for the "line" option. Some remote servers will place this
in the request URI instead. This adds an additional check for
the option in the request URI.

ASTERISK-25072 #close
Reported by: Dmitriy Serov

Change-Id: Id4e44debbb80baad623b914a88574371575353c8

10 years agores_mwi_external_ami: Use module version of AMI registration. 12/512/2
Corey Farrell [Thu, 21 May 2015 22:51:18 +0000 (18:51 -0400)] 
res_mwi_external_ami: Use module version of AMI registration.

Use ast_manager_register_xml for res_mwi_external_ami manager
actions.  This ensures the module is held open while any of
the actions are being run.

ASTERISK-25117 #close
Reported by: Corey Farrell

Change-Id: Iececfdc2da498b2c32b9e09042f5f12292007ac7

10 years agoARI: Update version to 1.7.0 06/506/1
Matt Jordan [Thu, 21 May 2015 18:05:08 +0000 (13:05 -0500)] 
ARI: Update version to 1.7.0

This patch updates the version of ARI to 1.7.0 to reflect the backwards
compatible changes that will be introduced in 13.4.0.

Change-Id: I6c36e6144da426412f25828a868e4df916bff60a

10 years agoMerge "audiohook.c: Difference in read/write rates caused continuous buffer resets...
Matt Jordan [Thu, 21 May 2015 12:22:14 +0000 (07:22 -0500)] 
Merge "audiohook.c: Difference in read/write rates caused continuous buffer resets" into 13

10 years agoMerge "Logger: Reset defaults before processing config." into 13
Matt Jordan [Thu, 21 May 2015 12:21:44 +0000 (07:21 -0500)] 
Merge "Logger: Reset defaults before processing config." into 13

10 years agoMerge "res/res_http_websocket: Add a pre-session established callback" into 13
Matt Jordan [Thu, 21 May 2015 12:20:56 +0000 (07:20 -0500)] 
Merge "res/res_http_websocket: Add a pre-session established callback" into 13

10 years agoMerge "main/sdp_srtp.c: allow SDP crypto tag to be up to 9 digits" into 13
Joshua Colp [Thu, 21 May 2015 10:15:29 +0000 (05:15 -0500)] 
Merge "main/sdp_srtp.c: allow SDP crypto tag to be up to 9 digits" into 13

10 years agoLogger: Reset defaults before processing config. 03/503/1
Corey Farrell [Thu, 21 May 2015 01:53:46 +0000 (21:53 -0400)] 
Logger: Reset defaults before processing config.

Reset options to default values before reloading config.  This ensures
that if a setting is removed or commented out of the configuration file
it is unset on reload.

ASTERISK-25112 #close
Reported by: Corey Farrell

Change-Id: Id24bb1fb0885c2c14cf8bd6f69a0c2ee7cd6c5bd

10 years agoapp_playback: Suppress warnings on playback if channel hung up 00/500/1
George Joseph [Thu, 21 May 2015 00:05:20 +0000 (18:05 -0600)] 
app_playback: Suppress warnings on playback if channel hung up

If a channel hangs up while an audio file is playing, there's
no need to clutter up the logs with a warning so suppress it
if ast_check_hangup returns true.

Also, change warning to debug/2 in file.c if writing a frame
fails.  Same reasoning.

Change-Id: I2e66191af3c5b6e951c98e8f1c3fe3cf2cf7ed89
Reported-by: George Joseph <george.joseph@fairview5.com>
Tested-by: George Joseph <george.joseph@fairview5.com>
10 years agoaudiohook.c: Difference in read/write rates caused continuous buffer resets 63/463/6
Kevin Harwell [Thu, 14 May 2015 20:21:23 +0000 (15:21 -0500)] 
audiohook.c: Difference in read/write rates caused continuous buffer resets

Currently, everytime a sample rate change occurs (on read or write) the
associated factory buffers are reset. If the requested sample rate on a
read differed from that of a write then the buffers are continually reset
on every read and write. This has the side effect of emptying the buffer,
thus there being no data to read and then write to a file in the case of
call recording.

This patch fixes it so that an audiohook_list's rate always maintains the
maximum sample rate among hooks and formats. Audiohook sample rates are
only overwritten by this value when slin native compatibility is turned on.
Also, the audiohook sample rate can only overwrite the list's sample rate
when its rate is greater than that of the list or if compatibility is
turned off. This keeps the rate from constantly switching/resetting.

ASTERISK-24944 #close
Reported by: Ronald Raikes

Change-Id: Idab4dfef068a7922c09cc631dda27bc920a6c76f

10 years agoMerge "Fix potential crash after unload of func_periodic_hook or test_message." into 13
Matt Jordan [Wed, 20 May 2015 20:22:58 +0000 (15:22 -0500)] 
Merge "Fix potential crash after unload of func_periodic_hook or test_message." into 13

10 years agomain/sdp_srtp.c: allow SDP crypto tag to be up to 9 digits 91/491/1
Corey Edwards [Tue, 19 May 2015 18:01:36 +0000 (12:01 -0600)] 
main/sdp_srtp.c: allow SDP crypto tag to be up to 9 digits

ASTERISK-24887 #close
Reported by: Makoto Dei
Tested by: tensai

Change-Id: I6a96f572adb17f76b3acafe503a01c48eb5dd9bf

10 years agores/res_http_websocket: Add a pre-session established callback 85/485/2
Matt Jordan [Wed, 13 May 2015 14:55:58 +0000 (09:55 -0500)] 
res/res_http_websocket: Add a pre-session established callback

This patch updates http_websocket and its corresponding implementation
with a pre-session established callback. This callback allows for
WebSocket server consumers to be notified when a WebSocket connection is
attempted, but before we accept it. Consumers can choose to reject the
connection, if their application specific logic allows for it.

As a result, this patch pulls out the previously private
websocket_protocol struct and makes it public, as
ast_websocket_protocol. In order to preserve backwards compatibility
with existing modules, the existing APIs were left as-is, and new APIs
were added for the creation of the ast_websocket_protocol as well as for
adding a sub-protocol to a WebSocket server.

In particular, the following new API calls were added:
* ast_websocket_add_protocol2 - add a protocol to the core WebSocket
  server
* ast_websocket_server_add_protocol2 - add a protocol to a specific
  WebSocket server
* ast_websocket_sub_protocol_alloc - allocate a sub-protocol object.
  Consumers can populate this with whatever callbacks they wish to
  support, then add it to the core server or a specified server.

ASTERISK-24988
Reported by: Joshua Colp

Change-Id: Ibe0bbb30c17eec6b578071bdbd197c911b620ab2

10 years agochan_pjsip: Fix crash during off-nominal when no endpoint specified. 76/476/8
snuffy [Fri, 15 May 2015 03:05:52 +0000 (13:05 +1000)] 
chan_pjsip: Fix crash during off-nominal when no endpoint specified.

Add missing return -1 when no endpoint name is specified.

ASTERISK-25086 #close
Reported by: snuffy

Change-Id: I9de76c2935a1f4e3f0cffe97a670106f5605e89e

10 years agores_pjsip_config_wizard/config: Fix template processing 73/473/4
George Joseph [Thu, 14 May 2015 23:01:56 +0000 (17:01 -0600)] 
res_pjsip_config_wizard/config: Fix template processing

The config wizard was always pulling the first occurrence of
a variable from an ast_variable list but this gets the template
value from the list instead of any overridden value.  This patch
creates ast_variable_find_last_in_list() in config.c and updates
res_pjsip_config_wizard to use it instead of
ast_variable_find_in_list.  Now the overridden values, where they
exist, are used instead of template variables.

Updated test_config to test the new API.

ASTERISK-25089 #close

Reported-by: George Joseph <george.joseph@fairview5.com>
Tested-by: George Joseph <george.joseph@fairview5.com>
Change-Id: Ifa7ddefc956a463923ee6839dd1ebe021c299de4

10 years agocdr: Fix 'core show channel' CDR variable truncation. 78/478/4
snuffy [Fri, 15 May 2015 06:54:26 +0000 (16:54 +1000)] 
cdr: Fix 'core show channel' CDR variable truncation.

When the new Bridging API was implemented, the workspace variable
changed to a malloc'd string, causing sizeof() to always be 8 (char).

Revert back to stored on stack string for workspace.

ASTERISK-25090 #close

Change-Id: I51e610ae87371df771ce7693a955510efb90f8f7

10 years agoMerge "sorcery: Add API to insert/remove a wizard to/from an object type's list"...
Joshua Colp [Thu, 14 May 2015 20:20:25 +0000 (15:20 -0500)] 
Merge "sorcery: Add API to insert/remove a wizard to/from an object type's list" into 13

10 years agoMerge "Message.c: Clear message channel frames on cleanup" into 13
Joshua Colp [Thu, 14 May 2015 20:19:55 +0000 (15:19 -0500)] 
Merge "Message.c: Clear message channel frames on cleanup" into 13

10 years agoFix potential crash after unload of func_periodic_hook or test_message. 67/467/2
Corey Farrell [Thu, 14 May 2015 05:06:53 +0000 (01:06 -0400)] 
Fix potential crash after unload of func_periodic_hook or test_message.

These modules save a pointer to the context they create on load, and
use that pointer to destroy the context at unload.  It is not safe
to save this pointer, it is replaced during load of pbx_config,
pbx_lua or pbx_ael.

This change causes the modules to pass NULL to ast_context_destroy,
a safer way to perform the unregistration since it does not use
a pointer that could become invalid.

ASTERISK-25085 #close
Reported by: Corey Farrell

Change-Id: I6a00ec8e38046058f97dc703e1adcde9bf517835

10 years agoMerge "main/manager.c: Bugfix sort action_manager by alphabetically" into 13
Joshua Colp [Thu, 14 May 2015 10:02:51 +0000 (05:02 -0500)] 
Merge "main/manager.c: Bugfix sort action_manager by alphabetically" into 13

10 years agoMessage.c: Clear message channel frames on cleanup 66/466/2
Jonathan Rose [Wed, 13 May 2015 20:41:07 +0000 (15:41 -0500)] 
Message.c: Clear message channel frames on cleanup

The message channel is a special channel that doesn't actually process frames.
However, certain actions can cause frames to be placed in the channel's read
queue including the Hangup application which is called on the channel after
each message is processed. Since the channel will continually be reused for
many messages, it's necessary to flush these frames at some point.

ASTERISK-25083 #close
Reported by: Jonathan Rose

Change-Id: Idf18df73ccd8c220be38743335b5c79c2a4c0d0f

10 years agoMerge "app_voicemail: fix moving when old messages full" into 13
Joshua Colp [Wed, 13 May 2015 20:44:39 +0000 (15:44 -0500)] 
Merge "app_voicemail: fix moving when old messages full" into 13

10 years agoapp_voicemail: fix moving when old messages full 61/461/2
Jonathan Rose [Tue, 12 May 2015 22:45:09 +0000 (17:45 -0500)] 
app_voicemail: fix moving when old messages full

When completing voicemail playback of a message in the 'INBOX', the
message gets moved to the 'Old' messages folder. Without this patch, if
the 'Old' folder is already at its set limit, then the 'INBOX' message will
simply be deleted. With this patch, the flag to delete the message will be
removed if the save_to_folder function indicates that the message could
not be moved due to a full folder.

ASTERISK-25082 #close
Reported by: Jonathan Rose
Review: https://gerrit.asterisk.org/#/c/448/

Change-Id: I2be440a09f42e2d06d50975c40d1ad7f836ecb3f

10 years agoMerge "General: Fix recent menuselect-related cross compile regression" into 13
Joshua Colp [Wed, 13 May 2015 19:20:42 +0000 (14:20 -0500)] 
Merge "General: Fix recent menuselect-related cross compile regression" into 13

10 years agoMerge "res_config_mysql: Fix broken column type checking" into 13
Joshua Colp [Wed, 13 May 2015 17:26:11 +0000 (12:26 -0500)] 
Merge "res_config_mysql: Fix broken column type checking" into 13

10 years agoMerge "chan_dahdi/sig_pri: Fix crash on ISDN call hangup collision." into 13
Joshua Colp [Wed, 13 May 2015 17:24:32 +0000 (12:24 -0500)] 
Merge "chan_dahdi/sig_pri: Fix crash on ISDN call hangup collision." into 13

10 years agomain/manager.c: Bugfix sort action_manager by alphabetically 59/459/1
Rodrigo Ramírez Norambuena [Tue, 5 May 2015 01:11:56 +0000 (21:11 -0400)] 
main/manager.c: Bugfix sort action_manager by alphabetically

Fix the alphabetic order added on ast_manager_register_struct. The order
for struct manager_action added is not working, this change fixes the
problem.

Change-Id: I149da0cd06c3c4445d7516cc303358e9f26f8b4b

10 years agores_config_mysql: Fix broken column type checking 56/456/1
Alexandre Fournier [Fri, 8 May 2015 23:01:26 +0000 (01:01 +0200)] 
res_config_mysql: Fix broken column type checking

MySQL configuration engine contains a bug in require_mysql(). This
function is used for column type checking in tables. This bug only
affects DATETIME, DATE and FLOAT types.

It came from mixing the first condition (switch-case-like
if/then/else), to check the expected column type, with the second
condition, to check the actual column type against the expected column
type. Both conditions must be checked separately in order to avoid the
execution of the wrong block.

ASTERISK-18252 #comment This patch might fix the issue
Reported by: Gareth Blades

ASTERISK-25041 #close
Reported by: Alexandre Fournier
Tested by: Alexandre Fournier

Change-Id: I0b8bf7e68ab938be8e6525a249260cb648cb0bfa

10 years agores_rtp_asterisk: Correction for the limit which detects that a packet is DTLS. 51/451/1
Yousf Ateya [Sun, 10 May 2015 12:37:54 +0000 (14:37 +0200)] 
res_rtp_asterisk: Correction for the limit which detects that a packet is DTLS.

First byte of DTLS packet shall be in range 20-63, not 20-64. Refer to RFC
https://tools.ietf.org/html/rfc5764#section-5.1.2 for correct values.

Change-Id: Iae6fa0d72b37c36a27fe40686e0ae6fba3afec31

10 years agoMerge "cdr_pgsql: Use PQescapeStringConn for escaping names." into 13
Joshua Colp [Wed, 13 May 2015 09:35:17 +0000 (04:35 -0500)] 
Merge "cdr_pgsql: Use PQescapeStringConn for escaping names." into 13

10 years agochan_dahdi/sig_pri: Fix crash on ISDN call hangup collision. 46/446/1
Richard Mudgett [Tue, 12 May 2015 22:34:45 +0000 (17:34 -0500)] 
chan_dahdi/sig_pri: Fix crash on ISDN call hangup collision.

If an ISDN call is hungup by both sides at the same time a crash could
happen.

* Added missing NULL checks for the owner channel after calling
pri_queue_pvt_cause_data() in two places.  Code after those calls need to
check the owner channel pointer for NULL before use because
pri_queue_pvt_cause_data() needs to do deadlock avoidance to lock the
owner and the owner may get hung up.

ASTERISK-21893 #close
Reported by:  Alexandr Gordeev

Change-Id: Ica3e266ebc7a894b41d762326f08653e1904bb9a

10 years agoGeneral: Fix recent menuselect-related cross compile regression 43/443/1
Sebastian Kemper [Sun, 10 May 2015 07:26:30 +0000 (09:26 +0200)] 
General: Fix recent menuselect-related cross compile regression

MAKE_MENUSELECT currently sets CC to CC, which is the compiler for the
target platform. But menuselect is to be run on the build system, so
BUILD_CC needs to be used instead - like it was in the past, before the
recent changes (https://reviewboard.asterisk.org/r/4370/). This is the
patch for ASTERISK-25074.

ASTERISK-25074 #close
Reported by: Sebastian Kemper
Tested by: Sebastian Kemper

Change-Id: I8a2b1fc5deb6ad2b80f49baca35b1b13d468ebf8

10 years agosorcery: Add API to insert/remove a wizard to/from an object type's list 94/394/7
George Joseph [Tue, 5 May 2015 20:32:08 +0000 (14:32 -0600)] 
sorcery: Add API to insert/remove a wizard to/from an object type's list

Currently you can 'apply' a wizard to an object type but the wizard
always goes at the end of the object type's wizard list.  This patch
adds a new ast_sorcery_insert_wizard_mapping function that allows
you to insert a wizard anyplace in the list.  I.E.  You could
add a caching wizard to an object type and place it before all
wizards.

ast_sorcery_get_wizard_mapping_count and
ast_sorcery_get_wizard_mapping were added to allow examination
of the mapping list.

ast_sorcery_remove_mapping was added to remove a mapping by name.

As part of this patch, the object type's wizard list was converted
from an ao2_container to an AST_VECTOR_RW.

A new test was added to test_sorcery for this capability.

ASTERISK-25044 #close

Change-Id: I9d2469a9296b2698082c0989e25e6848dc403b57

10 years agoFix processing of asterisk.conf debug=yes. 38/438/2
Corey Farrell [Tue, 12 May 2015 06:31:58 +0000 (02:31 -0400)] 
Fix processing of asterisk.conf debug=yes.

The code which reads asterisk.conf supports processing the debug
option with ast_true, but ast_true returns -1.  This causes debug
to still be off, convert to 1 so debug will be on as requested.

ASTERISK-25042
Reported by: Corey Farrell

Change-Id: I3c898b7d082d914b057e111b9357fde46bad9ed6

10 years agocdr_pgsql: Use PQescapeStringConn for escaping names. 41/441/1
Rodrigo Ramírez Norambuena [Sat, 2 May 2015 04:43:22 +0000 (00:43 -0400)] 
cdr_pgsql: Use PQescapeStringConn for escaping names.

Use function PQescapeStringConn for escaping the name
of the table and schema instead of doing it manually.

Change-Id: I6709165e2d00463e9c813d24f17830ad4910b599

10 years agoMerge "vector: Add REMOVE, ADD_SORTED and RESET macros" into 13
Joshua Colp [Tue, 12 May 2015 10:38:57 +0000 (05:38 -0500)] 
Merge "vector:  Add REMOVE, ADD_SORTED and RESET macros" into 13

10 years agovector: Add REMOVE, ADD_SORTED and RESET macros 21/421/8
George Joseph [Sat, 9 May 2015 21:58:46 +0000 (15:58 -0600)] 
vector:  Add REMOVE, ADD_SORTED and RESET macros

Based on feedback from Corey Farrell and Y Ateya, a few new
macros have been added...

AST_VECTOR_REMOVE which takes a parameter to indicate if
order should be preserved.

AST_VECTOR_ADD_SORTED which adds an element to
a sorted vector.

AST_VECTOR_RESET which cleans all elements from the vector
leaving the storage intact.

Change-Id: I41d32dbdf7137e0557134efeff9f9f1064b58d14

10 years agopbx/pbx_spool: Fix issue when call files were executed too early 33/433/2
Ivan Poddubny [Mon, 11 May 2015 12:07:31 +0000 (12:07 +0000)] 
pbx/pbx_spool: Fix issue when call files were executed too early

pbx_spool used to delete/move the call file upon successful outgoing
call completion, but did not delete it from in-memory list of files
(dirlist, used only when compiled with inotify/kqueue support).
That resulted in an extra attempt to process that filename after
retrytime seconds.
Then, if a new file with the same name appears that is scheduled
in future further than the completed one plus its retrytime,
then it gets executed earlier than expected.

This patch fixes remove_from_queue function to also remove the entry
from the dirlist.

ASTERISK-17069 #close
Reported by: Jeremy Kister

ASTERISK-24442 #close
Reported by: tootai

Change-Id: If9ec9b88073661ce485d6b008fd0b2612e49a28b

10 years agoconfigs/basic-pbx: Modified main IVR to play new Allison prompt. 19/419/1
Rusty Newton [Fri, 8 May 2015 19:47:51 +0000 (14:47 -0500)] 
configs/basic-pbx: Modified main IVR to play new Allison prompt.

The main IVR was playing demo-congrats. I've switched it over to the
basic-pbx-ivr-main file that we added in core sounds 1.4.27. This prompt
has Allison prompting the user with the actual IVR menu.

ASTERISK-24892 #close

Change-Id: Ifb749616ff8e156a1031ddaddfcc9244767a095d

10 years agoMerge "tcptls: Avoiding ERR_remove_state in OpenSSL." into 13
Matt Jordan [Fri, 8 May 2015 20:55:46 +0000 (15:55 -0500)] 
Merge "tcptls: Avoiding ERR_remove_state in OpenSSL." into 13

10 years agores_rtp_asterisk: Issue ERROR if res_srtp is not found. 10/410/4
Sean Bright [Fri, 8 May 2015 15:39:42 +0000 (15:39 +0000)] 
res_rtp_asterisk: Issue ERROR if res_srtp is not found.

While trying to get WebRTC working with chan_pjsip, I was running
into the following error:

    Attempted to set an invalid DTLS-SRTP configuration on RTP
    instance...

Josh helpfully pointed out that res_srtp.so might not be loaded, and
sure enough, it wasn't. This patch adds a ERROR indiciating as much
to hopefully help others having a similar problem.

Change-Id: I13aa477b47b299876728a21b130998a0ea6cd19f

10 years agosounds: Add Swedish sounds to Makefile and XML 14/414/1
Rusty Newton [Thu, 7 May 2015 22:49:07 +0000 (17:49 -0500)] 
sounds: Add Swedish sounds to Makefile and XML

Added the necessary lines to the Makefile and sounds.xml so we'll have the
Swedish sounds in all available formats in menuselect.

See also: Swedish sounds were added into the core sounds release 1.4.27.

ASTERISK-24744 #close

Reported by: Tove Hjelm
Tested by: Rusty Newton

Change-Id: Ib6f4fd177afd1667b2402735034001d4d055a908

10 years agoMerge "doc: Make progdocs play nice with git" into 13
Joshua Colp [Fri, 8 May 2015 14:54:47 +0000 (09:54 -0500)] 
Merge "doc: Make progdocs play nice with git" into 13

10 years agotcptls: Avoiding ERR_remove_state in OpenSSL. 05/405/1
Alexander Traud [Tue, 5 May 2015 16:35:16 +0000 (18:35 +0200)] 
tcptls: Avoiding ERR_remove_state in OpenSSL.

ERR_remove_state was deprecated with OpenSSL 1.0.0 and was replaced by
ERR_remove_thread_state. ERR_load_SSL_strings and ERR_load_BIO_strings were
called by SSL_load_error_strings already and got removed. These changes allow
OpenSSL forks like BoringSSL to be used with Asterisk.

ASTERISK-25043 #close
Reported by: Alexander Traud
patches:
  asterisk_with_BoringSSL.patch uploaded by Alexander Traud (License 6520)

Change-Id: If1c0871ece21a7e0763fafbd2fa023ae49d4d629
(cherry picked from commit 247fef66537b59649e7571d64e2c574a106dbd65)

10 years agodoc: Make progdocs play nice with git 99/399/2
George Joseph [Thu, 7 May 2015 19:54:35 +0000 (13:54 -0600)] 
doc: Make progdocs play nice with git

Moved contrib/asterisk-ng-doxygen to doc/asterisk-ng-doxygen.in

Changed /Makefile to copy asterisk-ng-doxygen.in to
asterisk-ng-doxygen then modify it with version instead of
modifying asterisk-ng-doxygen directly.  Updated clean
targets as well.

Updated /.gitignore and doc/.gitignore.

Change-Id: I38712d3e334fa4baec19d30d05de8c6f28137622

10 years agoMerge "res_pjsip_exten_state: Fix race condition between sending NOTIFY and terminati...
Joshua Colp [Thu, 7 May 2015 20:10:23 +0000 (15:10 -0500)] 
Merge "res_pjsip_exten_state: Fix race condition between sending NOTIFY and termination" into 13

10 years agocontrib/editors: Fix vim syntax highlighting of comments in config files 96/396/1
Ivan Poddubny [Mon, 4 May 2015 19:43:20 +0000 (19:43 +0000)] 
contrib/editors: Fix vim syntax highlighting of comments in config files

 * Added a lookbehind to one-line comment matcher to skip escaped
   semicolons.
 * Added support for block comments.

Change-Id: Id17dfaeda8ed4be572e8107a0c010066584aaee7

10 years agoMerge "vector: Additional enhancements and fixes" into 13
Matt Jordan [Thu, 7 May 2015 18:30:10 +0000 (13:30 -0500)] 
Merge "vector:  Additional enhancements and fixes" into 13

10 years agores_pjsip_exten_state: Fix race condition between sending NOTIFY and termination 89/389/1
Joshua Colp [Wed, 6 May 2015 18:24:29 +0000 (15:24 -0300)] 
res_pjsip_exten_state: Fix race condition between sending NOTIFY and termination

The res_pjsip_exten_state module currently has a race condition between
processing the extension state callback from the PBX core and processing
the subscription shutdown callback from res_pjsip_pubsub. There is currently
no synchronization between the two. This can present a problem as while
the SIP subscription will remain valid the tree it points to may not.
This is in particular a problem as a task to send a NOTIFY may get queued
which will try to use the tree that may no longer be valid.

This change does the following to fix this problem:

1. All access to the subscription tree is done within the task that
sends the NOTIFY to ensure that no other thread is modifying or
destroying the tree. This task executes on the serializer for the
subscriptions.

2. A reference to the subscription serializer is kept to ensure it
remains valid for the lifetime of the extension state subscription.

3. The NOTIFY task has been changed so it will no longer attempt
to send a NOTIFY if the subscription has already been terminated.

ASTERISK-25057 #close
Reported by: Matt Jordan

Change-Id: I0b3cd2fac5be8d9b3dc5e693aaa79846eeaf5643

10 years agoMerge "chan_dahdi: Improve force_restart_unavailable_chans option description." into 13
Matt Jordan [Thu, 7 May 2015 12:02:42 +0000 (07:02 -0500)] 
Merge "chan_dahdi: Improve force_restart_unavailable_chans option description." into 13

10 years agoMerge "res_stasis_snoop: Spying on a single direction continually increases CPU"...
Matt Jordan [Thu, 7 May 2015 11:39:20 +0000 (06:39 -0500)] 
Merge "res_stasis_snoop: Spying on a single direction continually increases CPU" into 13

10 years agoMerge "features: Fix crash when transferee hangs up during DTMF attended transfer...
Joshua Colp [Thu, 7 May 2015 11:28:00 +0000 (06:28 -0500)] 
Merge "features: Fix crash when transferee hangs up during DTMF attended transfer." into 13

10 years agovector: Additional enhancements and fixes 74/374/5
George Joseph [Wed, 6 May 2015 01:22:13 +0000 (19:22 -0600)] 
vector:  Additional enhancements and fixes

After using the new vector stuff for real I found...

A bug in AST_VECTOR_INSERT_AT that could cause a seg fault.

The callbacks needed to be closer to ao2_callback in behavior
WRT to CMP_MATCH and CMP_STOP behavior and the ability to return
a vector of matched entries.

A pre-existing issue with APPEND and REPLACE was also fixed.

I also added a new macro to test.h that acts like ast_test_validate
but also accepts a return code variable and a cleanup label.  As well
as printing the error, it sets the rc variable to AST_TEST_FAIL and
does a goto to the specified label on error.  I had a local version
of this in test_vector so I just moved it.

ASTERISK-25045

Change-Id: I05e5e47fd02f61964be13b7e8942bab5d61b29cc

10 years agores_stasis_snoop: Spying on a single direction continually increases CPU 56/356/4
Kevin Harwell [Mon, 4 May 2015 22:28:08 +0000 (17:28 -0500)] 
res_stasis_snoop: Spying on a single direction continually increases CPU

Creating a snoop channel in ARI and spying only on a single direction (in or
out) results in CPU utilization continually increasing until the CPU is fully
consumed. This occurs because frames are being put in the opposing direction's
slin factory queue, but not being removed.

Fixed the problem by always reading and disposing of frames from the opposite
queue of the direction selected.

ASTERISK-24938 #closes

Change-Id: I935bfd15f1db958f364d9d6b3b45582c0113dd60

10 years agochan_dahdi: Improve force_restart_unavailable_chans option description. 85/385/1
Richard Mudgett [Wed, 6 May 2015 21:00:40 +0000 (16:00 -0500)] 
chan_dahdi: Improve force_restart_unavailable_chans option description.

ASTERISK-25034
Reported by: Richard Mudgett

Change-Id: I1ff8f02124d2f4abd632a050da52c64285bb7f30

10 years agoMerge "app_queue: Fix queue_log EXITWITHTIMEOUT containing only 1 parameter" into 13
Joshua Colp [Wed, 6 May 2015 12:42:05 +0000 (07:42 -0500)] 
Merge "app_queue: Fix queue_log EXITWITHTIMEOUT containing only 1 parameter" into 13

10 years agoMerge "res_ari_bridges: Add missing dependencies." into 13
Matt Jordan [Wed, 6 May 2015 11:13:37 +0000 (06:13 -0500)] 
Merge "res_ari_bridges: Add missing dependencies." into 13

10 years agoMerge "pbx_config: Register manager actions with module version of macro." into 13
Matt Jordan [Wed, 6 May 2015 02:05:09 +0000 (21:05 -0500)] 
Merge "pbx_config: Register manager actions with module version of macro." into 13

10 years agofeatures: Fix crash when transferee hangs up during DTMF attended transfer. 72/372/1
Richard Mudgett [Tue, 5 May 2015 23:17:54 +0000 (18:17 -0500)] 
features: Fix crash when transferee hangs up during DTMF attended transfer.

A crash happens with this sequence of steps:
1) Party A is connected to party B.
2) Party B starts a DTMF attended transfer.
3) Party A hangs up while party B is dialing party C.

When party A hangs up the bridge that party A and party B are in is
dissolved and party B is kicked out of the bridge.  When party B finishes
dialing party C he attempts to move to the new bridge with party C.  Since
party B is no longer in a bridge the attempted move dereferences a NULL
bridge_channel pointer and crashes.

* Made the hold(), unhold(), ringing(), and the bridge_move() functions
tolerant of the channel not being in a bridge.  The assertion that party B
is always in a bridge is not true if the bridged peer of party B hangs up
and dissolves the bridge.  Being tolerant of not being in a bridge allows
the peer hangup stimulus to be processed by the FSM.

* Made the bridge_move() function return void since where the return value
for a failed move was checked generated a FSM coding ERROR message for a
normal off-nominal condition.

* Eliminated most uses of RAII_VAR in bridge_basic.c.

ASTERISK-25003 #close
Reported by: Artem Volodin

Change-Id: Ie2c1b14e5e647d4ea6de300bf56d69805d7bcada

10 years agotest_vector: Fix build breakage caused by ASTERISK_REGISTER_FILE 71/371/1
George Joseph [Tue, 5 May 2015 20:40:57 +0000 (14:40 -0600)] 
test_vector: Fix build breakage caused by ASTERISK_REGISTER_FILE

My 13 version of test_vector had an ASTERISK_REGISTER_FILE() macro
call at the top which is only supported in master.  Once removed
builds are successful.

Change-Id: I7cac8b669bed6de543bbf4e2eec3cffc9741acdd

10 years agoapp_queue: Fix queue_log EXITWITHTIMEOUT containing only 1 parameter 69/369/1
Ivan Poddubny [Tue, 5 May 2015 19:48:36 +0000 (19:48 +0000)] 
app_queue: Fix queue_log EXITWITHTIMEOUT containing only 1 parameter

This patch fixes EXITWITHTIMEOUT queue_log entry to always come with 3
parameters: position, original position and waiting time.

ASTERISK-25038 #close
Reported by: Etienne Lessard

Change-Id: I0c62045922e26bee2125e93aee1dee17eee79618

10 years agoMerge "stasis: Fix dial masquerade datastore lifetime" into 13
Matt Jordan [Tue, 5 May 2015 18:13:10 +0000 (13:13 -0500)] 
Merge "stasis: Fix dial masquerade datastore lifetime" into 13

10 years agoMerge "vector: Traversal, retrieval, insert and locking enhancements" into 13
Matt Jordan [Tue, 5 May 2015 17:45:43 +0000 (12:45 -0500)] 
Merge "vector:  Traversal, retrieval, insert and locking enhancements" into 13

10 years agores_ari_bridges: Add missing dependencies. 62/362/1
Corey Farrell [Tue, 5 May 2015 14:47:43 +0000 (10:47 -0400)] 
res_ari_bridges: Add missing dependencies.

Missed this module in the previous commit.  res_ari_bridges uses symbols
from res_stasis_playback and res_stasis_recording.

ASTERISK-25027 #close
Reported by: Corey Farrell

Change-Id: I90bf756abd25adfc4920d2869ebe7feb636b8c5f

10 years agopbx_config: Register manager actions with module version of macro. 60/360/1
Corey Farrell [Tue, 5 May 2015 14:27:15 +0000 (10:27 -0400)] 
pbx_config: Register manager actions with module version of macro.

Switch manager actions in pbx_config to use the registration macro that
passes the module pointer, allowing pbx_config reference to be bumped
while the manager actions run.

ASTERISK-25061 #close
Reported by: Corey Farrell

Change-Id: I422c50dd74814616ac10c5e9c6598a0b1bc2c44e

10 years agostasis: Fix dial masquerade datastore lifetime 57/357/1
Joshua Colp [Mon, 4 May 2015 17:16:24 +0000 (14:16 -0300)] 
stasis: Fix dial masquerade datastore lifetime

A recent change went into Asterisk which added reference counts to the
channels stored in a dial masquerade datastore. Unfortunately this
included a reference to the caller in a dialing operation. While all
of the dialed targets have the datastore removed from them upon dialing
completion this did not occur for the caller, causing it to have a
reference to itself that could go never go away (as it depended on
the destruction of the datastore which only happened when the channel
was destroyed). This resulted in the caller channel remaining on the
system despite it having hung up.

This change does the following to fix this issue:

1. The dial masquerade datastore is now removed from the caller upon
dialing completion, just like the dialed targets.
2. Upon destruction of the caller all the dialed targets are also
removed from the dial masquerade datastore (just in case).
3. The reference to the caller has been removed as it should not be
possible for the datastore to now be valid/useful after the lifetime
of the caller has ended.

ASTERISK-25025 #close

Change-Id: I1ef4ca5ca04980028604cc2af5d2992ac3431b3f

10 years agovector: Traversal, retrieval, insert and locking enhancements 39/339/7
George Joseph [Sat, 2 May 2015 00:25:17 +0000 (18:25 -0600)] 
vector:  Traversal, retrieval, insert and locking enhancements

Renamed AST_VECTOR_INSERT to AST_VECTOR_REPLACE because it really
does replace not insert.  The few users of AST_VECTOR_INSERT were
refactored.  Because these are macros, there should be no ABI
compatibility issues.

Added AST_VECTOR_INSERT_AT that actually inserts an element into the
vector at a specific index pushing existing elements to the right.

Added AST_VECTOR_GET_CMP that can retrieve from the vector based
on a user-provided compare function.

Added AST_VECTOR_CALLBACK function that will execute a function
for each element in the vector.  Similar to ao2_callback and
ao2_callback_data functions although the vector callback can take
a variable number of arguments.  This should allow easy migration
to a vector where a container might be too heavy.

Added read/write locked vector and lock manipulation macros.

Added unit tests.

ASTERISK-25045 #close

Change-Id: I2e07ecc709d2f5f91bcab8904e5e9340609b00e0

10 years agomain/test.c: Add test to verify there were no registration errors. 53/353/3
Corey Farrell [Sun, 3 May 2015 18:55:56 +0000 (14:55 -0400)] 
main/test.c: Add test to verify there were no registration errors.

This adds a test that will fail if any test failed to register. Also fail
if any test registration produced a warning about missing a leading or
trailing slash.

ASTERISK-25053 #close
Reported by: Corey Farrell

Change-Id: I93e50b8fcbcfa7f1f5b41b2c44a51685c09529c3

10 years agoMerge "contrib/ast-db-manage: Add Postgres ENUM type support in auto DTMF mode update...
Matt Jordan [Mon, 4 May 2015 14:26:10 +0000 (09:26 -0500)] 
Merge "contrib/ast-db-manage: Add Postgres ENUM type support in auto DTMF mode update" into 13

10 years agoMerge "cdr/cdr_csv.c: Add a new option to enable columns added in Asterisk 1.8" into 13
Matt Jordan [Mon, 4 May 2015 14:26:01 +0000 (09:26 -0500)] 
Merge "cdr/cdr_csv.c: Add a new option to enable columns added in Asterisk 1.8" into 13

10 years agoMerge "Format Interfaces: Prevent unload except by shutdown." into 13
Matt Jordan [Mon, 4 May 2015 14:25:35 +0000 (09:25 -0500)] 
Merge "Format Interfaces: Prevent unload except by shutdown." into 13

10 years agoMerge "res_odbc: Use negative connection cache for all connections" into 13
Matt Jordan [Mon, 4 May 2015 12:46:06 +0000 (07:46 -0500)] 
Merge "res_odbc: Use negative connection cache for all connections" into 13

10 years agores_odbc: Use negative connection cache for all connections 84/184/6
Martin Tomec [Tue, 21 Apr 2015 16:52:22 +0000 (18:52 +0200)] 
res_odbc: Use negative connection cache for all connections

Apply the negative connection cache setting to all connections,
even those that are not pooled. This ensures that the connection
will not be re-established before the negative connection cache
time is met.

ASTERISK-22708 #close

Change-Id: I431cc2e8584ab0b6908b3523d0a0e18c9a527271

10 years agoMerge "Remove unneeded uses of optional_api providers." into 13
Matt Jordan [Mon, 4 May 2015 09:03:50 +0000 (04:03 -0500)] 
Merge "Remove unneeded uses of optional_api providers." into 13

10 years agoMerge "Update configure.ac/Makefile for clang" into 13
Matt Jordan [Mon, 4 May 2015 09:03:10 +0000 (04:03 -0500)] 
Merge "Update configure.ac/Makefile for clang" into 13

10 years agoFormat Interfaces: Prevent unload except by shutdown. 51/351/1
Corey Farrell [Mon, 4 May 2015 02:03:13 +0000 (22:03 -0400)] 
Format Interfaces: Prevent unload except by shutdown.

Format interfaces cannot be unregistered, so the modules that provide them
need to be held open except by shutdown.

ASTERISK-25054 #close
Reported by: Corey Farrell

Change-Id: Iadbd9675bf0d30b8fded5a739b163db3ea2db8f3

10 years agocontrib/ast-db-manage: Add Postgres ENUM type support in auto DTMF mode update 49/349/1
Matt Jordan [Mon, 4 May 2015 01:28:52 +0000 (20:28 -0500)] 
contrib/ast-db-manage: Add Postgres ENUM type support in auto DTMF mode update

The upgrade script for auto DTMF mode (31cd4f4891ec) added in 88b0fa7755
failed to add ENUM support for Postgres databases. This requires a
specific import from the sqlalchemy.dialects.postgresql package. This
patch corrects this error, which allows for Postgres update scripts to
be generated.

ASTERISK-24706

Change-Id: I4742ac8efa533cd6f18e0bdd907b339a9aedf015

10 years agoterm: send proper reset sequence when black background is forced 42/342/1
D Tucny [Sat, 2 May 2015 00:50:22 +0000 (20:50 -0400)] 
term: send proper reset sequence when black background is forced

When using the force black background command-line option or configuration
option an invalid reset sequence is sent following a coloured output item
in the CLI, the result is that the colour is not 'turned off' and continues
until the next non-default coloured text output.

A reset sequence is already defined in term.c, but the ast_term_reset
function doesn't use it, instead building it's own invalid sequence and
returning that.

This patch changes that behaviour, removing the building of a reset sequence
and instead using the pre-built constant 'enddata' which is a suitable reset
sequence for this purpose.

ASTERISK-24896 #close
Reported by: Dan Tucny

Change-Id: I56323899123ae3264900389cae1f5b252aa3bf43

10 years agoMerge "Build System: Prevent unneeded changes to asterisk/buildopts.h." into 13
Matt Jordan [Sun, 3 May 2015 14:20:15 +0000 (09:20 -0500)] 
Merge "Build System: Prevent unneeded changes to asterisk/buildopts.h." into 13

10 years agoMerge "res_pjsip_dlg_options: Fix MODULEINFO section." into 13
Matt Jordan [Sun, 3 May 2015 14:19:05 +0000 (09:19 -0500)] 
Merge "res_pjsip_dlg_options: Fix MODULEINFO section." into 13

10 years agoRemove unneeded uses of optional_api providers. 40/340/1
Corey Farrell [Sat, 2 May 2015 23:58:40 +0000 (19:58 -0400)] 
Remove unneeded uses of optional_api providers.

A few cases exist where headers of optional_api provders are included but
not needed.  This causes unneeded calls to ast_optional_api_use.

* Don't include optional_api.h from sip_api.h.
* Move 'struct ast_channel_monitor' to channel.h.
* Don't include monitor.h from chan_sip.c, channel.c or features.c.

The move of struct ast_channel_monitor is needed since channel.c depends on
it.  This has no effect on users of monitor.h since channel.h is included
from monitor.h.

ASTERISK-25051 #close
Reported by: Corey Farrell

Change-Id: I53ea65a9fc9693c89f8bcfd6120649bfcfbc3478

10 years agoMerge "include/asterisk/channel.h: Fix typo" into 13
Matt Jordan [Sat, 2 May 2015 15:19:08 +0000 (10:19 -0500)] 
Merge "include/asterisk/channel.h: Fix typo" into 13

10 years agoMerge "Astobj2: Fix initialization order of refdebug and AO2_DEBUG." into 13
Matt Jordan [Sat, 2 May 2015 15:17:26 +0000 (10:17 -0500)] 
Merge "Astobj2: Fix initialization order of refdebug and AO2_DEBUG." into 13