Commit Graph

30446 Commits

Author SHA1 Message Date
Sean Bright fd0ca1c3f9 Remove as much trailing whitespace as possible.
Change-Id: I873c1c6d00f447269bd841494459efccdd2c19c0
2017-12-22 09:23:22 -05:00
Jenkins2 9ef97b5a91 Merge "Fix some invalid Unicode characters" 2017-12-22 07:36:07 -06:00
Jenkins2 667296c907 Merge "app_voicemail: Fix file copy error handling." 2017-12-22 07:32:58 -06:00
Sean Bright a1a179c09d Fix some invalid Unicode characters
configs/samples/minivm.conf.sample contains invalid UTF-8, but that
appears to be intentional.

Change-Id: I7b1e0d332f3380fd0425962a3c9c55f9b200c8cc
2017-12-21 10:26:53 -06:00
Jenkins2 0100c9267e Merge "Fix Common Typo's." 2017-12-21 08:40:22 -06:00
Joshua Colp b0b2b79cb4 Merge "docs: Remove old API changes documentation" 2017-12-21 07:06:26 -06:00
Jenkins2 cc2557e3e0 Merge "app_festival: Fix fd leak on connection failure." 2017-12-21 06:35:06 -06:00
Joshua Colp c7a0ad8b99 Merge "bridge: Old channel video source not set to NULL after unref." 2017-12-21 06:15:44 -06:00
Jenkins2 fd7a263ac5 Merge "core: Fix unused variable error in handle_show_sysinfo." 2017-12-21 05:51:26 -06:00
Corey Farrell f2f51ff4ea app_voicemail: Fix file copy error handling.
Fix error where input/output file descriptors would be closed multiple
times.

Change-Id: Iba5140b60cb7de79e3d5d92be3c256947aa99da9
2017-12-20 22:19:29 -05:00
Sean Bright 9415ec2877 docs: Remove old API changes documentation
Change-Id: I1bc7957121cc7ae27dca04acc3613f4e1858476a
2017-12-20 14:55:13 -06:00
Corey Farrell 1b80ffa495 Fix Common Typo's.
Fix instances of:
* Retreive
* Recieve
* other then
* different then
* Repeated words ("the the", "an an", "and and", etc).
* othterwise, teh

ASTERISK-24198 #close

Change-Id: I3809a9c113b92fd9d0d9f9bac98e9c66dc8b2d31
2017-12-20 12:40:01 -05:00
Richard Mudgett 3625e91586 manager.h: Bump AMI version
Change-Id: I62e6ddeb261ef012687e1fb6734c554e2499b6bf
2017-12-20 11:34:42 -06:00
Corey Farrell aaa3884d4a bridge: Old channel video source not set to NULL after unref.
The bridge holds onto the old channel video source after it's been
released.  This can lead to use after free errors.

ASTERISK-27229 #close

Change-Id: Ib2dab61677dd8a21f7ad53cdc9b8ca93297838b3
2017-12-20 11:23:08 -05:00
Corey Farrell c2850bfebc core: Fix unused variable error in handle_show_sysinfo.
Apparently in OSX it's possible for OSX to HAVE_SYSCTL but not
HAVE_SYSINFO or HAVE_SWAPCTL.  In this case freeswap caused an unused
variable error.

ASTERISK-26563 #close

Change-Id: I8ec5b1897b786cc1abaf62264aa75039eea05510
2017-12-20 11:13:13 -05:00
Jenkins2 4815be9aeb Merge "CLI: Address multiple issues." 2017-12-20 08:54:58 -06:00
Jenkins2 0b9396720a Merge "bridge: Stop music on hold on adding an arbitrary channel to a bridge" 2017-12-20 08:34:51 -06:00
Jenkins2 a711ac25f1 Merge "dns_core: Protect against array index violation." 2017-12-20 08:00:29 -06:00
Jenkins2 78fb99e5a3 Merge "res_rtp_asterisk: Avoid close the rtp/rtcp fd twice." 2017-12-20 07:55:33 -06:00
Corey Farrell fff7782cf5 app_festival: Fix fd leak on connection failure.
Change-Id: If5efaddcf735ff7d17e55c36cc1388946cee9e0f
2017-12-20 01:53:17 -05:00
Jenkins2 968993a297 Merge "chan_sip: Fix memory leaks." 2017-12-19 19:42:13 -06:00
Jenkins2 262eda7801 Merge "Remove constant conditionals (dead-code)." 2017-12-19 19:17:25 -06:00
Corey Farrell d51837a1b9 CLI: Address multiple issues.
* listen uses the variable `s` for the result from ast_poll() then
  overwrites it with the result of accept().  Create a separate variable
  poll_result to avoid confusion since ast_poll does not return a file
  descriptor.
* Resolve fd leak that would occur if setsockopt failed in listen.
* Reserve an extra byte while processing completion results from remote
  daemon.  This fixes a bug where completion processing used strstr() on
  a string that was not '\0' terminated.  This was no risk to the Asterisk
  daemon, the bug was only reachable the remote console process.
* Resolve leak in handle_showchan when the channel is not found.
* Multiple leaks and a deadlock in pbx_config CLI completion.
* Fix leaks in "manager show command".

Change-Id: I8f633ceb1714867ae30ef4e421858f77c14485a9
2017-12-19 16:43:49 -05:00
Jenkins2 204dd027dd Merge "core: Fix multiple trivial issues in the core." 2017-12-19 14:46:02 -06:00
George Joseph 33213a5220 Merge "chan_console: Use correct parameter for 'set active'" 2017-12-19 14:20:19 -06:00
George Joseph 88f7f4ebb6 Merge "main/app: Fix leaks." 2017-12-19 14:19:42 -06:00
George Joseph 5554bc6b53 Merge "app_queue: Add feature to set wrapuptime on the queue member" 2017-12-19 14:15:48 -06:00
Corey Farrell b8f54f742f dns_core: Protect against array index violation.
Add a check to allocate_dns_record to prevent calling a pointer
retrieved from beyond dns_alloc_table.

ASTERISK-27495 #close

Change-Id: Ie2f6e4991cea46baa12e837bd64cc22b44d322bb
2017-12-19 14:50:11 -05:00
Corey Farrell 3c037ef972 chan_sip: Fix memory leaks.
In change_redirecting_information variables we use ast_strlen_zero to
see if a value should be saved.  In the case where the value is not NULL
but is a zero length string we leaked.

handle_response_subscribe leaked a reference to the ccss monitor
instance.

Change-Id: Ib11444de69c3d5b2360a88ba2feb54d2c2e9f05f
2017-12-19 14:47:26 -05:00
Jenkins2 a100baccb5 Merge "func_callerid: Initialize app argument structures." 2017-12-19 11:49:51 -06:00
Ivan Poddubny 3b99a0332c bridge: Stop music on hold on adding an arbitrary channel to a bridge
When a channel that is on hold gets added to a bridge by
the Bridge AMI action or the dialplan application of the same name,
music continues to play, causing "robotic sound".

This commit adds a call to ast_moh_stop to stop the music.
Also, it makes the AMI Park action use the right MOH class when the
channel gets parked.

Reported by: Zane Conkle

ASTERISK-25079 #close

Change-Id: I4b129c5a20c15e63968842460ac5a1a85903cf9f
2017-12-19 18:17:52 +01:00
Jenkins2 7384abc5c1 Merge "bridge_softmix.c: Don't match dead streams." 2017-12-19 11:12:22 -06:00
Jenkins2 6bd25cad86 Merge "rtp_engine.c: Eliminate rtcp_report_to_json() RAII_VAR usage." 2017-12-19 10:51:07 -06:00
Jenkins2 ece673f0f6 Merge "bridge_softmix.c: Change remove_destination_streams() return meaning." 2017-12-19 10:37:53 -06:00
Jenkins2 758b321f4c Merge "ast_json_pack(): Use safer json ref mechanism." 2017-12-19 10:23:41 -06:00
Jenkins2 a788e2e796 Merge "app_voicemail: Fix memory management issues." 2017-12-19 10:08:18 -06:00
George Joseph d68482fce2 Merge "bridge_softmix: Fix memory leaks." 2017-12-19 09:51:25 -06:00
Corey Farrell b3e839debd Remove constant conditionals (dead-code).
Some variables are set and never changed, making them constant.  This
means that code in the 'false' block of the conditional is unreachable.

In chan_skinny and res_config_ldap I used preprocessor directive `#if 0`
as I'm unsure if the unreachable code could be enabled in the future.

Change-Id: I62e2aac353d739fb3c983cf768933120f5fba059
2017-12-19 09:42:19 -05:00
Oron Peled c02e256407 chan_console: Use correct parameter for 'set active'
chan_console supports multiple devices but the CLI only works on a
single device. 'console set active' selects this device.

Sadly that CLI picks the wrong command-line parameter and will only
work for a device called 'active'.

ASTERISK-27490 #close

Change-Id: I2f0e5fe63db19845bee862575b739360797dc73d
2017-12-19 14:12:57 +02:00
Corey Farrell bf33a09c37 core: Fix multiple trivial issues in the core.
* Fix small leaks in from error conditions in sdp.c and translate.c.
* Check new file descriptor is less than 0, not less than or equal.

Change-Id: Id7782775486175c739e0c4bf3ea5e17e3f452a99
2017-12-19 00:36:24 -05:00
Aaron An 81474dfb23 res_rtp_asterisk: Avoid close the rtp/rtcp fd twice.
When RTCP-MUX enabled. rtp->s is the same as rtcp->s, check this before
close the file descriptor. Close the FD twice will hangs the asterisk
under heavy load.

ASTERISK-27299 #close
Reported-by: Aaron An
Tested-by: AaronAn

Change-Id: I870a072d73fd207463ac116ef97100addbc0820a
2017-12-19 10:39:55 +08:00
Corey Farrell 8dfc973d64 main/app: Fix leaks.
* ast_linear_stream would leak a file descriptor if it failed to allocate
  lin.
* ast_control_tone leaked zone and ts if ast_playtones_start failed.

Additionally added whitespace to ast_linear_stream, pulled assignments
out of conditionals for improved readability.

Change-Id: I6d1a10cf9161b1529d939b9b2d63ea36d395b657
2017-12-18 21:04:31 -05:00
Corey Farrell a790ced2e8 func_callerid: Initialize app argument structures.
This module uses AST_DEFINE_APP_ARGS_TYPE to define struct's instead of
directly using AST_DECLARE_APP_ARGS.  Initialize the variables declared
in this way.

Change-Id: If97fbdd8d63a204e2efd498a192effc14e90fb31
2017-12-18 20:35:12 -05:00
Richard Mudgett 4c04e13783 bridge_softmix.c: Change remove_destination_streams() return meaning.
The return value of remove_destination_streams() now means we removed a
stream from the topology by making it a dead stream.  Now we won't try to
request a topology change if we didn't remove any streams.

Change-Id: Icd91571d856a1d04299a24c411e325c1d9d5c61d
2017-12-18 18:55:13 -06:00
Richard Mudgett ea4179599f bridge_softmix.c: Don't match dead streams.
* Made is_video_source() and is_video_dest() not match dead streams.

* Optimized is_video_dest() to reduce duplicated code.

Change-Id: I4e7ab762c7ee98395e78e6516399f57a2609b9a1
2017-12-18 18:51:23 -06:00
Corey Farrell 91d9eae79b bridge_softmix: Fix memory leaks.
Change-Id: Ifaf3e93b398595d21d07f535330fef77ff15a80c
2017-12-18 19:40:08 -05:00
Richard Mudgett f6393b59af ast_json_pack(): Use safer json ref mechanism.
Change-Id: I49204db2e57ae96eee43909c18ed007c09ac817e
2017-12-18 18:05:29 -06:00
Corey Farrell dc04d1ec93 app_voicemail: Fix memory management issues.
* mwi_sub_event_cb: mwist leaked on separate_mailbox failure.
* add_email_attachment: A reference to sox_gain_tmpdir was used
  after the storage was out of scope.

Change-Id: I6282c542ff7b82fa091177a912d11234a8b00a30
2017-12-18 19:04:56 -05:00
Richard Mudgett 7054fb8756 rtp_engine.c: Eliminate rtcp_report_to_json() RAII_VAR usage.
Change-Id: I58a22c2ca82e91d7537409b7b3af2d735827a54d
2017-12-18 18:02:09 -06:00
Jenkins2 11a1e07ad2 Merge "netsock: Remove from Asterisk core." 2017-12-18 17:40:22 -06:00