Commit Graph

30243 Commits

Author SHA1 Message Date
George Joseph
6faa428a38 Merge "app_voicemail: Fix json blob errors" into 13 2018-03-19 09:02:51 -05:00
Corey Farrell
bd926539b0 main/translate: Use ast_cli_completion_add.
Change-Id: I0e2402660e54d91f74ab0804c62a5b1925577413
2018-03-18 21:00:16 -06:00
Corey Farrell
d202b56a74 main/taskprocessor: Use ast_cli_completion_add.
Change-Id: Ie5f812a988ed811fd11967151932de62bc131b48
2018-03-18 20:36:10 -06:00
Corey Farrell
18cbfcf4f0 aco: Use ast_cli_completion_add for 'config show help'.
In addition this removes:
* RAII_VAR usage
* Duplicate check of pos
* Unneeded arguments.

Change-Id: I2da8eac2670d1d8d6474c04037129804f55ebf39
2018-03-18 18:28:58 -06:00
Corey Farrell
d57b58f5e9 main/config: Use ast_cli_completion_add for reload completion.
Change-Id: Ia3fa4c03f2285a1ec8814bbe7f4624ead9111ad1
2018-03-18 18:09:47 -06:00
Corey Farrell
34e16cbf3a main/bridge: Use ast_cli_completion_add.
Change-Id: I3775a696d6a57139fdf09651ecb786bcf1774509
2018-03-17 18:44:52 -06:00
Corey Farrell
98a3baca70 core: Minor cleanup of ast_el_read_char.
* Define CHAR_T_LIBEDIT and CHAR_TO_LIBEDIT based on
  HAVE_LIBEDIT_IS_UNICODE.  This avoids needing to repeatedly use
  conditional blocks, eliminates having multiple function prototypes.
* Remove parenthesis from return values.
* Add missing code block brackets {}.
* Reduce use of 'else' conditional statements where possible.

Change-Id: I4315328ebea2f62641faf6881de2ac20a9f9d08e
2018-03-17 16:47:54 -06:00
Alexander Traud
7b40605d8e BuildSystem: Check for header file of OGG.
Asterisk uses various symbols of the shared library libogg within the module
format_ogg_vorbis. However, the source code of that module did not include the
header file of libogg explicitly but implicitly. Because that header was not
included before Asterisk 14, the script ./configure was told not to check for
it.

Anyway, even Asterisk 13 LTS uses symbols of libogg. Therefore, that header
should be included explicitly. Therefore, ./configure should check for that
header.

Change-Id: I98c50d56311b68880d1084fcc62c35ab2f8692db
2018-03-17 16:54:09 +01:00
Alexander Traud
06ba605988 BuildSystem: When no download utility is available, display the explanation.
./configure --with-pjproject-bundled
did not display an explanation, when no download utility like wget, curl, or
fetch was installed beforehand, although an explanation existed in code. This
happened because the code expected the variable DOWNLOAD_TO_STDOUT to be empty.
However, the script ./configure set that variable always.

Change-Id: I64c99b76a03525c69471e5055bf124b36a51bbd4
2018-03-17 07:16:48 -06:00
Alexander Traud
0f634c1446 BuildSystem: Remove unused dependency on libltdl.
Asterisk does not need the development package of libltdl, because it does not
use any symbol of -lltdl directly. Instead, it uses the runtime package via the
shared library -lodbc. On the supported platforms, that shared library declares
its dependency on -lltdl correctly, otherwise AST_EXT_LIB_CHECK would have
failed.

ASTERISK-27745

Change-Id: Icd315809b8e7978203431f3afb66240dd3a040ba
2018-03-17 04:02:17 -06:00
Joshua Colp
b50331626e Merge "cli: Enable ast_cli_completion_add on public completion generators." into 13 2018-03-16 18:59:52 -05:00
Jenkins2
1f2ff45626 Merge "main/ccss: Use ast_cli_completion_add for core id." into 13 2018-03-16 18:59:16 -05:00
Alexander Traud
c0c537c1d3 BuildSystem: In NetBSD, the Python Programming Language is python-X.Y.
ASTERISK-27717

Change-Id: If90ddf9c396c32e7402a894f42dce215c30049d1
2018-03-16 10:42:15 -06:00
Jenkins2
3b49fb3446 Merge "astobj2_container: Use ast_cli_completion_add for container names." into 13 2018-03-16 11:05:04 -05:00
George Joseph
3bc40401a7 Merge "main/channel: Use ast_cli_completion_add for channeltypes." into 13 2018-03-16 10:35:01 -05:00
Alexander Traud
afcd1dd8e5 BuildSystem: Avoid an extra case for OpenBSD.
Nine years ago with Mantis 13639 (now ASTERISK-12841) an extra case for OpenBSD
was introduced: Vorbis required Ogg to be specified manually, because the shared
library libvorbis.so did not specify its required dependency on -logg itself.

Today with OpenBSD 6.2, all libvorbis*.so declare their dependencies correctly.
Therefore, an extra case is not required anymore.

Change-Id: Ifd04e0994ce9f1e4ad29c3948a0398b91d1e97bc
2018-03-16 09:11:59 -06:00
Alexander Traud
5b80e97fff BuildSystem: Enable Advanced Linux Sound Architecture (ALSA) in NetBSD.
In the script ./configure, AST_EXT_LIB_CHECK checks for external libraries. Some
libraries do not specify all their dependencies and require additional shared
libraries. In AST_EXT_LIB_CHECK, this is the fifth parameter. However, if a
library is specified there, it must exist on the platform, because ./configure
tries to compile/link/execute a small app using those statements. For example,
the library libdl.so is Linux specific and does not exist on BSD-like platforms.

Furthermore, no supported platform/version was found, which still (ever?)
requires those additional libraries. Therefore, they were simply removed.

Finally, this change adds the error code ESTRPIPE to the channel driver
chan_alsa for those platforms which lack it, again for example NetBSD.

ASTERISK-27720

Change-Id: I3b21f2135f6cbfac7590ccdc2df753257f426e0b
2018-03-16 16:09:31 +01:00
George Joseph
d5af24bb14 app_voicemail: Fix json blob errors
When app_voicemail calls ast_test_suite_notify with the results of
a user keypress, it formats the keypress as '%c'.  If the user hung up
or some other error occurrs, the result of the keypress is a non
printable character.  This ultimately causes json_vpack_ex to think
it's being passed a non utf-8 string and return an error.

* Keypress results passed to ast_test_suite_notify are now checked with
  isprint() and a '?' is substituted if the check fails.

Change-Id: I78ee188916bbac840f3d03f40201b692347ea865
2018-03-16 08:02:20 -06:00
Florian Floimair
69463c612d app_dial: Enable early-media video
Certain applications (e.g. door-phone) require that also video is transmitted
before a call is accepted.

Change-Id: I9842e1dc2f6e1c2c49dc33fe615255007d2f821e
2018-03-16 12:35:51 +01:00
Corey Farrell
a7ebb9409d main/cdr: Use ast_cli_completion_add for CDR channel completion.
Change-Id: Ie81830647a23aad61c1162583b6d50adbe6e7822
2018-03-15 11:55:58 -06:00
Corey Farrell
5ac64a4464 main/ccss: Use ast_cli_completion_add for core id.
Change-Id: I44b25d6d24c7d9bc1bb38a50774b38883162f98f
2018-03-15 07:57:27 -06:00
Alexander Traud
e04be32fc5 install_prereq: Add Arch Linux.
ASTERISK-27738

Change-Id: I7ca620e3c4dfb4b064a19382c4915aeb42a2a09f
2018-03-15 14:27:07 +01:00
Corey Farrell
eb699f3631 core: Backport compatible MALLOC_DEBUG changes.
* Add support for MALLOC_DEBUG and DEBUG_CHAOS to be used together.
* Add utils/astmm.c to .gitignore.
* Fix MALLOC_DEBUG variant of __ast_vasprintf.  This function called
  va_end(ap) upon allocation failure.  This is incorrect since ap is
  passed as an argument.

Change-Id: I9f27ced4ce3cbe4b39547a67f994fdff491978c0
2018-03-15 06:57:38 -06:00
Corey Farrell
7e0c56f800 astobj2_container: Use ast_cli_completion_add for container names.
Change-Id: I4f0fc09e820eb8d8da2354a177dbcf503c56ddd1
2018-03-15 06:31:32 -06:00
Corey Farrell
7e041d6233 main/channel: Use ast_cli_completion_add for channeltypes.
Change-Id: Ia845fae6a84801cc7d9996767b99efb2753cbb48
2018-03-15 06:25:44 -06:00
Joshua Colp
c78f4b8e61 Merge "res_pjsip_rfc3326.c: Account for more than one 'Reason' header" into 13 2018-03-15 06:47:09 -05:00
Jenkins2
adb0bebe66 Merge "install_prereq: Add SUSE." into 13 2018-03-15 06:39:03 -05:00
Corey Farrell
6539b89254 cli: Enable ast_cli_completion_add on public completion generators.
* ast_cli_complete
* ast_complete_channels
* ast_complete_applications

These generators will now use ast_cli_completion_add if state == -1.

Change-Id: I7ff311f0873099be0e43a3dc5415c0cd06d15756
2018-03-15 05:27:41 -06:00
Jenkins2
a243fed64f Merge "core: Remove incorrect usage of attribute_malloc." into 13 2018-03-14 20:53:38 -05:00
Ross Beer
96eaabd920 res_pjsip_rfc3326.c: Account for more than one 'Reason' header
ASTERISK-27741

Change-Id: I0aa59a54735c6d20b95c54db1bd095dbf93e7adf
2018-03-14 18:36:41 -05:00
Alexander Traud
b237ef7f27 install_prereq: Add SUSE.
ASTERISK-27736

Change-Id: I4cafc8973349d50a7cb7919ddf0bb1aaef4bfc3e
2018-03-14 15:01:32 +01:00
Jenkins2
029c9383aa Merge "core: Remove non-critical cleanup from startup aborts." into 13 2018-03-14 06:40:38 -05:00
Joshua Colp
ed7d24d0c1 Merge "BuildSystem: Enable IMAP storage on openSUSE and Arch Linux." into 13 2018-03-14 06:34:33 -05:00
Joshua Colp
acf3bdc3d5 Merge "res_srtp: Add support for libsrtp2.x on openSUSE." into 13 2018-03-14 06:34:17 -05:00
Joshua Colp
d13ef8c974 Merge "BuildSystem: Add NetBSD." into 13 2018-03-14 06:07:47 -05:00
Jenkins2
f518380dba Merge "install_prereq: Add NetBSD." into 13 2018-03-13 18:34:43 -05:00
Jenkins2
fb4c995ad5 Merge "BuildSystem: Re-check for another UUID library only when previous check failed." into 13 2018-03-13 17:54:12 -05:00
Jenkins2
c42508aeb6 Merge "BuildSystem: Enable PortAudio in NetBSD." into 13 2018-03-13 17:47:34 -05:00
Corey Farrell
dc738b145f core: Remove incorrect usage of attribute_malloc.
GCC documentation states that when __attribute__((malloc)) is used it
should not return storage which contains any valid pointers.  It
specifically mentions that realloc functions should not have the malloc
attribute, but this also means that complex initializers which could
contain initialized pointers should not use this attribute.

Change-Id: If507f33ffb3ca3b83b702196eb0e8215d27fc7d2
2018-03-13 17:37:12 -04:00
Alexander Traud
7533d25e8d BuildSystem: Enable IMAP storage on openSUSE and Arch Linux.
ASTERISK-27734

Change-Id: I8d6e6a1c08c031649764f5277fbbb85e57c3a9d4
2018-03-13 16:26:18 -05:00
Jenkins2
0a402dc851 Merge "res_pjproject.c: Upgrade bundled PJPROJECT to 2.7.2" into 13 2018-03-13 15:20:46 -05:00
Joshua Colp
e3c76be75b Merge "BuildSystem: For consistency, avoid double-checking via if clauses." into 13 2018-03-13 10:43:16 -05:00
George Joseph
aae7fd6508 Merge "BuildSystem regression: Fix errors reported by clean targets." into 13 2018-03-12 09:46:01 -05:00
Jenkins2
9b630985a1 Merge "BuildSystem: Enable Lua in NetBSD." into 13 2018-03-12 09:02:45 -05:00
Joshua Colp
f05ac26d4a Merge "Replace direct checks of option_debug with DEBUG_ATLEAST macro." into 13 2018-03-12 08:35:51 -05:00
Jenkins2
af79e3091f Merge "BuildSystem: Depend not implicitly but explicitly on external libraries." into 13 2018-03-12 07:07:54 -05:00
Alexander Traud
09c43fdc1a res_srtp: Add support for libsrtp2.x on openSUSE.
Since ASTERISK-26976, libSRTP 2.x can be used for sRTP. However, that change
added a private header which is not available on openSUSE for example. To
remain compatibility with very old libSRTP versions, the affected/missing
symbols AES_128_ICM and HMAC_SHA1 are defined manually.

ASTERISK-27733

Change-Id: I25c5cb8fa966043d1506ebef449e5a724412b4b6
2018-03-12 10:22:43 +01:00
Corey Farrell
c09a10bb1b core: Remove non-critical cleanup from startup aborts.
When built-in components of Asterisk fail to start they cause the
Asterisk startup to abort.  In these cases only the most critical
cleanup should be performed - closing databases and terminating
proceses.  These cleanups are registered using ast_register_atexit, all
other cleanups should not be run during startup abort.

The main reason for this change is that these cleanup procedures are
untestable from the partially initialized states, if they fail it could
prevent us from ever running the critical cleanup with ast_run_atexits.

Change-Id: Iecc2df98008b21509925ff16740bd5fa29527db3
2018-03-10 04:33:33 -05:00
Alexander Traud
bd6e0b1a72 BuildSystem: Add NetBSD.
Headers, libraries, and rpath.

ASTERISK-27728
ASTERISK-11015
Reported by: Curt Sampson

Change-Id: I50aa5fcd095937df32a2e33307caac7e79a8b5b7
2018-03-09 10:10:16 -06:00
Alexander Traud
ba88af8a25 BuildSystem: For consistency, avoid double-checking via if clauses.
In the script ./configure, AST_EXT_LIB_CHECK and AST_PKG_CONFIG_CHECK first test
whether parameter 1 was already found. Consequently, an if-test on PBX_ just a
line below is redundant, if exactly the same parameter 1 is used again.

No performance gain is expected by this change. However, because this strategy
is used all over in ./configure except for two places, this change aims to
create more consistency: Only do something different if there is a reason to do
so.

Change-Id: I4a6f48127b7af3a48168c917e888be1f70625027
2018-03-09 10:23:53 +01:00