Commit Graph

31037 Commits

Author SHA1 Message Date
Kevin Harwell
4ea20c9c85 mwi core: Move core MWI functionality into its own files
There is enough MWI functionality to warrant it having its own 'c' and header
files. This patch moves all current core MWI data structures, and functions
into the following files:

main/mwi.h
main/mwi.c

Note, code was simply moved, and not modified. However, this patch is also in
preparation for core MWI changes, and additions to come.

Change-Id: I9dde8bfae1e7ec254fa63166e090f77e4d3097e0
2019-04-23 17:39:40 -05:00
Friendly Automation
e1e9274c57 Merge "ARI: Bump non-breaking version number to 1.10.2" into 13 2019-04-23 16:42:00 -05:00
Friendly Automation
72170f73e4 Merge "core/buildsystem: check the actual compiler being version" into 13 2019-04-23 15:23:41 -05:00
George Joseph
6d4023e3a6 ARI: Bump non-breaking version number to 1.10.2
main/json.c: Added app_name, app_data to channel type
res/res_ari: Added ARI resource /ari/channels/{channelId}/rtp_statistics
res/res_ari: Added timestamp as a requirement for all ARI events

Change-Id: Ie0da5b0cf0623b0d0fddbb864f73cb676c2b55cd
2019-04-22 14:45:01 -06:00
Friendly Automation
dcd26ce6ac Merge "res_indications: Fix indications remove command autocomplete" into 13 2019-04-22 08:48:50 -05:00
Guido Falsi
8ee69fbdd0 core/buildsystem: check the actual compiler being version
Make compiler check use the output of the actual compiler being
used as reported by the CC variable, instead of unconditionally
running the "gcc" binary.  Also only run the check if the compiler
is gcc or a cross-compile gcc.

ASTERISK-28374

Change-Id: Icaacf6d93686ad21076878aa1504a23b4fc9d0f4
2019-04-22 07:04:40 -06:00
Lucas Mendes
aaee0fa6f5 res_indications: Fix indications remove command autocomplete
We changed the validation of autocomplete parameter in the "indications
remove" command to avoid continue the execution of the command after
asking for autocomplete out of range parameters.

ASTERISK-28391
Reported by: lmendes86

Change-Id: I92b24131fd02f2e3c7fec966eea6f7a663310d40
2019-04-19 16:33:49 +02:00
Dan Cropp
00588226c6 res_pjsip: Added a norefersub configuration setting
Added a new PJSIP global setting called norefersub.
Default is true to keep support working as before.

res_pjsip_refer:  Configures PJSIP norefersub capability accordingly.

Checks the PJSIP global setting value.
If it is true (default) it adds the norefersub capability to PJSIP.
If it is false (disabled) it does not add the norefersub capability
to PJSIP.

This is useful for Cisco switches that do not follow RFC4488.

ASTERISK-28375 #close
Reported-by: Dan Cropp

Change-Id: I0b1c28ebc905d881f4a16e752715487a688b30e9
2019-04-18 08:05:39 -06:00
Friendly Automation
94bbd75745 Merge "res_mwi_devstate: Specify AST_MODFLAG_LOAD_ORDER to enable load priority" into 13 2019-04-18 05:40:54 -05:00
Friendly Automation
bb1280b8c1 Merge "pbx.c: Ignore dashes in extensions when using extenpatternmatchnew" into 13 2019-04-16 12:09:24 -05:00
Friendly Automation
57f4bbf61f Merge "app_voicemail: Don't split mailbox options on comma" into 13 2019-04-16 11:32:19 -05:00
Sean Bright
33ed8fdadc res_mwi_devstate: Specify AST_MODFLAG_LOAD_ORDER to enable load priority
Suggested by abelbeck on the issue tracker.

ASTERISK~28384
Reported by: abelbeck

Change-Id: Icee0fff2b58dbfaa80f2b68270fe69dfb0463fc0
2019-04-16 12:03:52 -04:00
Benjamin Keith Ford
d15f01b294 Merge "build: Revise CHANGES and UPGRADE.txt handling." into 13 2019-04-16 10:52:21 -05:00
Joshua Colp
4cde7de0f0 Merge "res_ael: Use Gosub in for loop expressions" into 13 2019-04-16 08:08:51 -05:00
Joshua Colp
2a0e47e9cb Merge "res_ael: Fix pattern matching against literal '+'" into 13 2019-04-16 07:25:32 -05:00
George Joseph
e61e436b38 Merge "CI: Move test group config files to Jenkins" into 13 2019-04-15 08:06:21 -05:00
George Joseph
2fe9fd5cf9 CI: Move test group config files to Jenkins
One of the downaides of having things like test configuration
in the git repo is that it can't be changed at runtime.  You have
to create a review for the changes and merge it mefore it will
take effect.

This review moves the data currently held in
tests/CI/periodic-dailyTestGroups.json and
tests/CI/gateTestGroups.json into a Jenkins Config File attached
to the job definitions.  This allows us to alter it from the
Jenkins UI at runtime.  The original files stay in the repo
as documentation.

Change-Id: I14b9702f6285ce1fb2420287ba0e7d3b59109763
2019-04-15 06:48:18 -06:00
Sean Bright
d2f519dcfa app_voicemail: Don't split mailbox options on comma
Because the per-mailbox options are the last thing on a line, don't look
for or stomp on any subsequent commas.

ASTERISK-27935 #close
Reported by: Sébastien Duthil

Change-Id: I07b2eb4a33c303d0c7114d5b906f8c067c60a153
2019-04-13 14:37:46 -04:00
George Joseph
52b956e3eb Merge "res_ael: Create consistent label names across reloads" into 13 2019-04-12 14:16:19 -05:00
George Joseph
0eebc70592 Merge "pbx.c: Properly parse labels with leading digits" into 13 2019-04-12 14:15:59 -05:00
Sean Bright
79a620080c pbx.c: Ignore dashes in extensions when using extenpatternmatchnew
Because hyphens are not matched literally in Asterisk dialplan, we need
to ignore them in our candidate extensions as well.

ASTERISK-17695 #close
Reported by: test011

Change-Id: I227f02301577b1633e8a55b9fe9dc149935c03f0
2019-04-12 11:21:58 -04:00
Friendly Automation
13af11b495 Merge "app_voicemail: Cleanup stale lock files on module load" into 13 2019-04-12 09:59:42 -05:00
Friendly Automation
ce92860995 Merge "chan_ooh323: fix h323 log file path" into 13 2019-04-12 09:18:16 -05:00
Sean Bright
fd2e8d0da7 app_voicemail: Cleanup stale lock files on module load
If Asterisk crashes while a VM directory is locked, lock files in the VM
spool directory will not get properly cleaned up. We now clear them on
module load.

ASTERISK-20207 #close
Reported by: Steven Wheeler

Change-Id: If40ccd508e2f6e5ade94dde2f0bcef99056d0aaf
2019-04-12 07:13:20 -06:00
Sean Bright
9051e62523 res_ael: Create consistent label names across reloads
Reset the internal counter that the AEL2 compiler uses for unique label
names before compiling. This keeps dialplan labels consistent across
reloads assuming the AEL2 has not changed.

ASTERISK-17799 #close
Reported by: Kirill Katsnelson

Change-Id: I30b3cc887d1ee0644d3f341e2fef16f525d7fae5
2019-04-11 16:49:36 -04:00
Sean Bright
237989a5e8 res_ael: Use Gosub in for loop expressions
In AEL2, if a 'for' statement contains macro* calls, like:

    for (&iterator(${TRY},A); "${A}" != ""; &iterate(A)) {

The AEL2 parser will translate these into calls to the deprecated Macro
dialplan application and use the antiquated pipe delimiter.

Instead, convert these into calls to the Gosub dialplan application and
use commas as argument separators.

ASTERISK-18593 #close
Reported by: Luke-Jr

* 'macro' in this context means AEL2 macros, not the 'Macro' application

Change-Id: I3d73716033b8e3e42e0209d355bf5f10c97045fc
2019-04-11 16:36:49 -04:00
Sean Bright
f66f21895f res_ael: Fix pattern matching against literal '+'
When generating the regular expression that matches against existing
extensions, we need to escape literal characters that can also be
regular expression metacharacters. This was already being done for '*'
but we need to do the same for '+'.

In passing, remove some unreachable code - strcmp() is already run
immediately when entering extension_matches().

ASTERISK-14939 #close
Reported by: klaus3000

Change-Id: I8d2cccb3479168fba1b0a6704c52198b396468f1
2019-04-11 14:10:25 -06:00
George Joseph
a981ec141d Merge "res_pjsip: Fix transport_states ref leak" into 13 2019-04-11 15:00:29 -05:00
Sean Bright
7666fdc394 pbx.c: Properly parse labels with leading digits
If the target of a Goto is a label that starts with a number, we
erroneously treat the leading digits as a priority.

ASTERISK-20182 #close
Reported by: Janu

Change-Id: Ia78408c0805a729103917247ecfc802f6fafc94b
2019-04-11 14:37:34 -04:00
Alexander Anikin
9a1e8090c3 chan_ooh323: fix h323 log file path
Change h323 log path relative to AST_LOG_DIR instead of
/var/log/asterisk hardcoded
Add return back error message from OOH323EP initialize

ASTERISK-28348 #close

Reported by: Dmitry Shubin

Change-Id: Ib102dd36bbe6c2a7a4ce6870ae9110d9000d7e98
2019-04-11 02:12:16 +03:00
George Joseph
1a4fbaa52e Merge "chan_pjsip: DTMF Mode auto_info fallback lead to both inband and info" into 13 2019-04-10 12:43:15 -05:00
Alexei Gradinari
cb24eb4cc2 res_pjsip: Fix transport_states ref leak
Add missing ao2_ref(transport_state, -1) while iterate on a transport_states
container.

Change-Id: I40e35b5a339121300c80075c30db47201a6c374e
2019-04-10 08:37:59 -06:00
Joshua Colp
cef62d4ffc Merge "config.c: Fix a crash in extconfig parsing" into 13 2019-04-10 06:40:46 -05:00
Ben Ford
251348cbbb build: Revise CHANGES and UPGRADE.txt handling.
This changes the way that we handle adding changes to CHANGES and
UPGRADE.txt. The reason for this is because whenever someone needed to
make a change to one of these files and someone else had already done
so, you would run into merge conflicts. With this new setup, there will
never be merge conflicts since all changes will be documented in the
doc/<file>-staging directory. The release script is now responsible for
merging all of these changes into the appropriate files.

There is a special format that these files have to follow in order to be
parsed. The files do not need to have a meaningful name, but it is
strongly recommended. For example, if you made a change to pjsip, you
may have something like this "res_pjsip_relative_title", where
"relative_title" is something more descriptive than that. Inside each
file, you will need a subject line for your change, followed by a
description. There can be multiple subject lines. The file may look
something like this:

   Subject: res_pjsip
   Subject: Core

   A description that explains the changes made and why. The release
   script will handle the bulleting and section separators!

   You can still separate with new lines within your description.

The headers ("Subject" and "Master-Only") are case sensative, but the
value for "Master-Only" ("true" or "True") is not.

For more information, check out the wiki page:
https://wiki.asterisk.org/wiki/display/AST/CHANGES+and+UPGRADE.txt

ASTERISK-28111 #close

Change-Id: I19cf4b569321c88155a65e9b0b80f6d58075dd47
2019-04-09 09:39:37 -05:00
Friendly Automation
6531f8b2ea Merge "CI: Add --no-dev-mode option to buildAsterisk.sh" into 13 2019-04-08 10:53:20 -05:00
Friendly Automation
e7de71ee24 Merge "main/json.c: Added app_name, app_data to channel type" into 13 2019-04-08 10:34:56 -05:00
Friendly Automation
7b64432c4e Merge "res/res_ari: Added ARI resource /ari/channels/{channelId}/rtp_statistics" into 13 2019-04-08 10:27:07 -05:00
Chris-Savinovich
f9bb53a1dd config.c: Fix a crash in extconfig parsing
When extconfig.conf file is parsed, the code previously searched for
character comma without verifying if error (null or blank).  This caused
a segmentation error.

Change-Id: Id76b452d8f330d11c2742c37232761ad71472a8b
2019-04-05 15:41:50 -06:00
Salah Ahmed
a9a0303544 chan_pjsip: DTMF Mode auto_info fallback lead to both inband and info
When the dtmf_mode on an endpoint is configured as "auto_info"
Asterisk will produce an inband DTMF tone alongside an INFO
message when sending DTMF.

ASTERISK-28371

Change-Id: I1380b82f006e110a1b83fbb50c9873edd13a5d9a
2019-04-05 08:29:12 -03:00
sungtae kim
707897e5f7 main/json.c: Added app_name, app_data to channel type
It was difficult to check the channel's current application and
parameters using ARI for current channels. Added app_name, app_data
items to show the current application information.

ASTERISK-28343

Change-Id: Ia48972b3850e5099deab0faeaaf51223a1f2f38c
2019-04-05 02:28:25 +02:00
Friendly Automation
a5b463cabf Merge "res/res_rtp_asterisk: Enable rxjitter calculation for video" into 13 2019-04-04 08:29:18 -05:00
George Joseph
b3faf7311a CI: Add --no-dev-mode option to buildAsterisk.sh
The new option disables dev mode, TEST_FRAMEWORK and
MALLOC_DEBUG making the build more production-like.

Change-Id: Ieb72497d4d91d5416684aaed702cc3f532099738
2019-04-03 16:55:00 -06:00
Ben Ford
4853fc2218 build: Fix compiler warnings/errors.
The compiler complained about a couple of variables that weren't
initialized but were being used. Initializing them to NULL resolves the
warnings/errors.

ASTERISK-28362 #close

Change-Id: I6243afc5459b416edff6bbf571b0489f6b852e4b
2019-04-03 09:36:28 -06:00
Matthew Fredrickson
1c7bc63cff res/res_rtp_asterisk: Enable rxjitter calculation for video
It looks like we're not properly calculating jitter values on received
video streams.  This patch enables the code that does jitter calculations
for those streams.

Change-Id: Iaac985808829c8f034db8c57318789c4c8c11392
2019-04-02 15:48:27 +00:00
George Joseph
d049155303 Merge "pjproject: Add timer patch from pjproject r5934" into 13 2019-04-02 10:28:15 -05:00
Friendly Automation
664f706771 Merge "alembic: Fix errors during upgrade head." into 13 2019-03-28 14:46:35 -05:00
Ben Ford
4de27f332d alembic: Fix errors during upgrade head.
When trying to upgrade using alembic, a couple different errors kept
popping up that prevented the upgrade. An additional parameter was
needed when changing the schema for mwi_subscribe_replaces_unsolicited
from an integer to an enum. When changing from a string to an enum, the
type needed to be cast for postgresql. The other issue was a parameter
being used during column creation that did not exist.

After fixing the upgrade process, it revealed errors with the downgrade
process. One was a variable not being defined in the downgrade function,
and the other was tables not existing when using MySQL. This was due to
a context check that should have encompassed MySQL, but in the end was
not doing so.

Change-Id: Ib4d70cf3ce5080023a50be496272a777b55d6c8e
2019-03-28 09:17:46 -05:00
George Joseph
0fdfac87f3 Merge "manager: Use separate lock for session event notification." into 13 2019-03-28 08:03:51 -05:00
Friendly Automation
df4a7a8fae Merge "pjsip: restrict function PJSIP_PARSE_URI to parse only SIP/SIPS URIs" into 13 2019-03-27 18:05:59 -05:00
sungtae kim
fb7aa52ae0 res/res_ari: Added ARI resource /ari/channels/{channelId}/rtp_statistics
Added ARI resource for channel statistics.
GET /ari/channels/{channelId}/rtp_statistics : It returns given
channel's rtp statistics detail.

ASTERISK-28320

Change-Id: I4343eec070438cec13f2a4f22e7fd9e574381376
2019-03-27 22:55:49 +01:00