Commit Graph

22223 Commits

Author SHA1 Message Date
Asterisk Autobuilder
ae00ec7d58 Importing release summary for 1.8.18.0 release.
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0@375940 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.8.18.0
2012-11-06 15:06:57 +00:00
Asterisk Autobuilder
7c703037a6 Update version, ChangeLog
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0@375937 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-06 15:01:54 +00:00
Asterisk Autobuilder
2df05ae107 Create 1.8.18.0
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0@375934 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-06 14:58:13 +00:00
Asterisk Autobuilder
c88fc44088 Use autotagged externals
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0-rc1@374681 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.8.18.0-rc1
2012-10-08 20:42:05 +00:00
Asterisk Autobuilder
d93f06ba52 Importing release summary for 1.8.18.0-rc1 release.
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0-rc1@374680 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-08 20:41:57 +00:00
Asterisk Autobuilder
d69b1c4861 Importing files for 1.8.18.0-rc1 release.
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0-rc1@374679 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-08 20:41:50 +00:00
Asterisk Autobuilder
93739e317a Creating tag for the release of asterisk-1.8.18.0-rc1
git-svn-id: https://origsvn.digium.com/svn/asterisk/tags/1.8.18.0-rc1@374678 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-08 20:41:01 +00:00
David M. Lee
40da12652e I've committed too much. Reverting part of r374570.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374581 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-05 20:20:28 +00:00
David M. Lee
8451fec7ec Improve AMI long line error handling
In AMI's parser, when it receives a long line (> 1024 characters), it discards
that line, but continues to process the message normally.

Typically, this is not a problem because a) who has lines that long and b)
usually a discarded line results in an invalid message. But if that line is
specifying an optional field, then the message will be processed, you get a
'Response: Success', but things don't work the way you expected them to.

This patch changes the behavior when a line-too-long parse error occurs.

* Changes the log message to avoid way-too-long (and truncated anyways) log
  messages
* Adds a 'parsing' status flag to Response: Success
* Sets parsing = MESSAGE_LINE_TOO_LONG if, well, a line is too long
* Responds with an appropriate error if parsing != MESSAGE_OKAY

(closes issue AST-961)
Reported by: John Bigelow
Review: https://reviewboard.asterisk.org/r/2142/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374570 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-05 20:14:41 +00:00
Richard Mudgett
e9a0f5a4e3 Merged revisions 374515-374535 from
https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier

................
  r374515 | rmudgett | 2012-10-04 17:52:36 -0500 (Thu, 04 Oct 2012) | 10 lines

  chan_misdn: Remove some deadcode

  * Made setup_bc() static.

  Patches:
	patch1_unused-code.diff (license #6372) patch uploaded by Guenther Kelleter
	Modified

  JIRA ABE-2882

................
  r374516 | rmudgett | 2012-10-04 18:01:01 -0500 (Thu, 04 Oct 2012) | 7 lines

  chan_misdn: Remove unused bchan states

  Patches:
	patch2_unused-states.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374517 | rmudgett | 2012-10-04 18:17:51 -0500 (Thu, 04 Oct 2012) | 16 lines

  chan_misdn: Remove unnecessary null pointer checks and checks for stack->nt

  * cleanup_bc() is always called with valid bc (or it would've crashed
  before).

  * Value of stack->nt is known in advance at some places.

  * Rename handle_event() to handle_event_te(), handle_frm() to
  handle_frm_te().

  Patches:
	patch3_checks.diff (license #6372) patch uploaded by Guenther Kelleter
	Modified

  JIRA ABE-2882

................
  r374518 | rmudgett | 2012-10-04 18:21:59 -0500 (Thu, 04 Oct 2012) | 7 lines

  chan_misdn: Fix spelling in log messages

  Patches:
	patch4_spelling.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374519 | rmudgett | 2012-10-04 18:31:59 -0500 (Thu, 04 Oct 2012) | 15 lines

  chan_misdn: Don't cleanup a bc twice.

  In handle_frm_te() after calling misdn_lib_send_event(bc,
  EVENT_RELEASE_COMPLETE) bc is emptied, cleaned and set not in use,
  although misdn_lib_send_event() already did the same.  This is bad.  When
  it's not in use we are not allowed to touch it.

  * Moved log message in front of the resulting actions and fixed it to
  match the case.

  Patches:
	patch5_bccleanup.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374520 | rmudgett | 2012-10-04 18:43:56 -0500 (Thu, 04 Oct 2012) | 12 lines

  chan_misdn: Fix memory leaks, bc, chan not cleaned up etc., really bad stuff.

  * Fix return codes of cb_events() for EVENT_SETUP to use caller's cleanup
  mechanisms.

  * Move cl_queue_chan() call after bearer check.

  Patches:
	patch6_leaks.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374521 | rmudgett | 2012-10-04 18:48:38 -0500 (Thu, 04 Oct 2012) | 11 lines

  chan_misdn: We must initialize cause on sending a DISCONNECT.

  We must initialize cause on sending a DISCONNECT, so it is later correctly
  indicated to ast_channel in case the answer (RELEASE/RELEASE_COMPLETE)
  does not include one.

  Patches:
	patch7_hangupcause.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374522 | rmudgett | 2012-10-04 19:03:56 -0500 (Thu, 04 Oct 2012) | 7 lines

  chan_misdn: Remove unused code for upqueue

  Patches:
	patch8_unused-upqueue.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374523 | rmudgett | 2012-10-04 19:11:50 -0500 (Thu, 04 Oct 2012) | 7 lines

  chan_misdn: Improve debugging (port number, messages fixed, dups removed)

  Patches:
	patch9_debug.diff (license #6372) patch uploaded by Guenther Kelleter

  JIRA ABE-2882

................
  r374533 | rmudgett | 2012-10-05 12:17:18 -0500 (Fri, 05 Oct 2012) | 8 lines

  chan_misdn: Better debug: we can print_bc_info even if there's no ast leg.

  Patches:
	patch10_debug-bc-2.diff (license #6372) patch uploaded by Guenther Kelleter
	Modified.

  JIRA ABE-2882

................
  r374534 | rmudgett | 2012-10-05 12:34:10 -0500 (Fri, 05 Oct 2012) | 16 lines

  chan_misdn: setup_bc() is called too early for an incoming SETUP on TE.

  This prevents the B channel from being setup for HDLC mode when requested
  by the bearer capability and config option hdlc=yes.  It violates
  ETS300102 Ch.5.2.3.2: "The user, in any case, must not connect to the
  channel until a CONNECT ACKNOWLEDGE message has been received."

  * Call setup_bc() on receipt of CONNECT_ACKNOWLEGDE for PTMP, and on first
  response to SETUP for PTP.

  Patches:
	abe-2881-2.diff (license #6372) patch uploaded by Guenther Kelleter
	Modified.

  JIRA ABE-2881

................
  r374535 | rmudgett | 2012-10-05 12:41:05 -0500 (Fri, 05 Oct 2012) | 2 lines

  chan_misdn: Remove some more deadcode.

................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374536 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-05 18:20:01 +00:00
Alec L Davis
5b6aa46f43 dsp.c User Configurable DTMF_HITS_TO_BEGIN and DTMF_MISSES_TO_END
Instead of a recompile, allow values to be adjusted in dsp.conf

For binary distributions allows easy adjustment for wobbly GSM calls, and other reasons.

Defaults to DTMF_HITS_TO_BEGIN=2 and DTMF_MISSES_TO_END=3

(closes issue ASTERISK-17493)
Reported by: alecdavis
Tested by: alecdavis
alecdavis (license 585)

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374479 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 20:15:35 +00:00
Alec L Davis
f4977cb24b dsp.c fix incorrect DTMF Digit_Duration.
it's always short by 'hits_to_begin*DTMF_GSIZE', or 25.5ms if hitstobegin=2

(issue ASTERISK-16003)
Tested by: alecdavis
alecdavis (license 585)

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374475 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 20:03:26 +00:00
Joshua Colp
3a013aab68 Fix a regression from direct media ACLs where the directrtpsetup option no longer works.
A check was added for direct media ACLs that immediately forbid remote bridging if there
was no bridged channel. This caused directrtpsetup to no longer function as it needs this
information before bridging actually occurs.

Logic has now been adjusted so if there is no bridged channel a remote bridge will still
be attempted.

(closes issue ASTERISK-20511)
Reported by: kristoff

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374456 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 17:39:18 +00:00
David M. Lee
2075c52a31 Fix DBDelTree error codes for AMI, CLI and AGI
The AMI DBDelTree command will return Success/Key tree deleted successfully even
if the given key does not exist. The CLI command 'database deltree' had a
similar problem, but was saved because it actually responded with '0 database
entries removed'. AGI had a slightly different error, where it would return
success if the database was unavailable.

This came from confusion about the ast_db_deltree retval, which is -1 in the
event of a database error, or number of entries deleted (including 0 for
deleting nothing).

* Adds a Doxygen comment to process_db_keys explaining its retval
* Changed some poorly named res variables to num_deleted
* Specified specific errors when calling ast_db_deltree (database unavailable
  vs. entry not found vs. success)
* Fixed similar bug in AGI database deltree, where 'Database unavailable'
  results in successful result

(closes issue AST-967)
Reported by: John Bigelow
Review: https://reviewboard.asterisk.org/r/2138/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374426 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 15:25:50 +00:00
Alec L Davis
57e403e023 dsp.c User configuration of DTMF_NORMAL_TWIST and DTMF_REVERSE_TWIST values
Asterisk's DTMF Specifications are based on AT&T specs, which may not be compatible in other countries.

Various countries have different specifications for the maximum power level differences
between the DTMF low group and high group of frequencies.

Power level difference between frequencies for different Administrations/RPOAs
 NTT        = Max. 5 dB
 AT&T       = 4dB(reverse) to 8dB(normal)
 Danish     = Max. 6 dB
 Australian = Max. 10 dB
 Brazilian  = Max. 9 dB
 ETSI       = Max. 6 dB from ETSI ES 201 235-3 V1.3.1 (2006-03)

Now allow 4 variables to be individually configured in dsp.conf, with reasonable min/max of 2dB to 20dB.
Default is AT&T specifications

Add's the following variables to dsp.conf
;dtmf_normal_twist=6.31 
;dtmf_reverse_twist=2.51 
;relax_dtmf_normal_twist=6.31 
;relax_dtmf_reverse_twist=3.98 


(closes issue ASTERISK-20442)
Reported by: tbsky
Tested by: tbsky,alecdavis

alecdavis (license 585)

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374384 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 04:39:04 +00:00
Alec L Davis
22efa62079 _dsp_init: bring inline with trunk
preparation for clean merge of DTMF TWIST patch

No functional changes, just style.

alecdavis (license 585)
Reported by: Alec Davis
Tested by: alecdavis

related https://reviewboard.asterisk.org/r/2141


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374365 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 04:15:29 +00:00
Matthew Jordan
1664ec1c61 Check for presence of buddy in info/dinfo handlers
The res_jabber resource module uses the ASTOBJ library for managing its ref
counted objects.  After calling ASTOBJ_CONTAINER_FIND to locate a buddy object,
the pointer to the object has to be checked to see if the buddy existed.
Prior to this patch, the buddy object was not checked for NULL; with this patch
in both aji_client_info_handler and aji_dinfo_handler the pointer is checked
before used and, if no buddy object was found, the handlers return an error
code.

This patch does not take the approach that our JID can be used to log in from
another resource.  If that approach is desired, an improvement could be made to
this patch to create the buddy on the fly.  This patch seeks only to prevent
Asterisk from crashing.

Note that multiple people have proposed patches for this issue; the patch being
committed here is based on those.

(closes issue ASTERISK-19532)
Reported by: Karsten Wemheuer
Tested by: Byron Clark
patches:
  fix-jabber uploaded by Karsten Wemheuer (license #5930)
  xmpp_no_crash_with_ejabberd.patch uploaded by Byron Clark (license #6157)

(closes issue ASTERISK-19557)
Reported by: ulugutz



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374335 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04 02:09:43 +00:00
Matthew Jordan
aa0cfe5035 Destroy the generic_monitors container after the core_instances in ccss
For each item in core_instances disposed of in the shutdown of ccss, any
generic monitor instances referenced by the objects will be removed from
generic_monitors during their destruction.  Hilarity ensues if
generic_monitors no longer exists.

Thanks to the Asterisk Test Suite's generic_ccss test for complaining loudly
when it ran into this.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374316 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-03 18:58:45 +00:00
Matthew Jordan
da1af69fd3 Ensure Shutdown AMI event is still fired during Asterisk shutdown
Richard pointed out that having the manager dispose of itself gracefully
during shutdown meant that the Shutdown event will no longer get fired.
This patch moves the AMI event just prior to running the atexit callbacks.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374230 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-02 20:54:16 +00:00
Matthew Jordan
c61f7e7995 Fix a variety of ref counting issues
This patch resolves a number of ref leaks that occur primarily on Asterisk
shutdown.  It adds a variety of shutdown routines to core portions of
Asterisk such that they can reclaim resources allocate duringd initialization.

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



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374177 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-02 00:31:14 +00:00
Sean Bright
509c3ebaf7 app_queue: Support persisting and loading of long member lists.
Greenlight in #asterisk brought up that he was receiving an error message "Could
not create persistent member string, out of space" when running app_queue in
Asterisk 10.  dump_queue_members() made an assumption that 8K would be enough to
store the generated string, but with queues that have large member lists this is
not always the case.  This patch removes the limitation and uses ast_str instead
of a fixed sized buffer.

The complicating factor comes from the fact that ast_db_get requires a buffer
and buffer size argument, which doesn't let us pull back more than what we pass
in, so I introduced a new ast_db_get_allocated() which returns an ast_strdup()'d
copy of the value from astdb.

As an aside, I did some testing on the maximum size of data that we can store in
the BDB library we distribute and was able to store a 10MB string and retrieve
it with no problems, so I feel this is a safe patch.

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374108 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-01 16:45:53 +00:00
Jonathan Rose
e9f70dc149 res_jabber: Remove CLI command 'jabber test'
The opinion of development was that it is both improper to have Matt's
personal email address used in the source and that the command wouldn't
be useful without it.

(closes issue AST-467)
Reported by: Malcolm Davenport


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@374032 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28 19:03:19 +00:00
Joshua Colp
25a7d7ecc7 Update documentation to make it explicit that "stream file" will not restart musiconhold.
(issue ASTERISK-17367)
Reported by: oej


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373989 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28 12:14:14 +00:00
Richard Mudgett
727c378636 Fix SendDTMF crash and channel reference leak using channel name parameter.
The SendDTMF channel name parameter has two issues.
1) Crashes if the channel name does not exist.
2) Leaks a channel reference if the channel is the current channel.
Problem introduced by ASTERISK-15956.

* Updated SendDTMF documentation.

* Renamed app to senddtmf_name and tweaked the type.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373945 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-27 22:08:24 +00:00
Joshua Colp
6d3973330d loader: Ensure dependent modules are properly initialized.
If an Asterisk module specifies a dependency in ast_module_info.nonoptreq, it
is possible for Asterisk to skip calling the modules's .load function.
Asterisk was loading and linking the module via load_dynamic_module() but was
not adding the module to the resource_heap. Therefore the module was not
initialized based on it's priority along with the other modules in the heap.

Now use load_resource() instead of load_dynamic_module() for non-optional
requirement. This will add the module to the resource_heap so the module can
be properly initialized in the correct order.

This is required if there are any module global data structures initialized in
the .load() callback for the module on platforms which do not support weak
references.

(issue ASTERISK-20439)
Reported by: sruffell
Patches:
     0001-loader-Ensure-dependent-modules-are-properly-initial.patch uploaded by sruffell (license 5417)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373909 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-27 16:49:54 +00:00
Joshua Colp
2d421def0f Fix an issue where Local channels dialed by app_queue are considered in use immediately.
The chan_local channel driver returns a device state of in use even if a created Local
channel has not yet been dialed. This fix changes the logic to return a state of not
in use until the channel itself has been dialed.

(closes issue ASTERISK-20390)
Reported by: tim_ringenbach

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373878 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-27 11:31:23 +00:00
Mark Michelson
38048cdbfa Move handling of 408 response so there is no misleading warning message.
(closes issue ASTERISK-20060)
Reported by: Walter Doekes



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373848 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-26 21:11:00 +00:00
Richard Mudgett
277e9a8358 Fixed meetme tab completion and command documentation.
* Removed unnecessary case sensitivity in meetme list, lock, unlock, mute,
unmute, and kick commands.

* Separated meetme lock/unlock, mute/unmute, and kick commands into their
own registered commands to simplify tab completion and parameter checking.
meetme_lock_cmd(), meetme_mute_cmd(), and meetme_kick_cmd()

* Simplified meetme_show_cmd()

(closes issue AST-1006)
Reported by: John Bigelow
Tested by: rmudgett


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373815 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-26 18:04:33 +00:00
Mark Michelson
ee1ca213e0 Fix saying of date in Dutch.
The Dutch say the date before the month.

(closes issue ASTERISK-20353)
Reported by: Teun Ouwehand



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373773 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 23:07:59 +00:00
Mark Michelson
f442b40687 Remove dead code and documentation for nonexistent feature.
multiplelogin was removed from chan_agent back in 1.6.0 when
AgentCallbackLogin() was removed.

(closes issue AST-948)
reported by Steve Pitts



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373768 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 22:47:36 +00:00
Mark Michelson
eb6ad1d9a9 Fix error where improper IMAP greetings would be deleted.
(closes issue ASTERISK-20435)
Reported by: fhackenberger
Patches:
	asterisk-20435-imap-del-greeting.diff uploaded by Michael L. Young (License #5026)
	(with suggested modification made by me)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373735 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 21:11:38 +00:00
Joshua Colp
67ef3e49d2 Fix T.38 support when used with chan_local in between.
Users of the T.38 API can indicate AST_T38_REQUEST_PARMS on a channel to request that the
channel indicate a T.38 negotiation with the parameters present on the channel. The return
value of this indication is expected to be AST_T38_REQUEST_PARMS upon success but with
chan_local involved this could never occur.

This fix changes chan_local to always return AST_T38_REQUEST_PARMS for this situation. If
the underlying channel technology on the other side does not support T.38 this would have
been determined ahead of time using ast_channel_get_t38_state and an indication would
not occur.

(closes issue ASTERISK-20229)
Reported by: wdoekes
Patches:
     ASTERISK-20229.patch uploaded by wdoekes (license 5674)

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373705 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 20:10:13 +00:00
Kinsey Moore
3be2ff5fe6 Fix an issue where media would not flow for situations where the legacy STUN code is in use.
The STUN packets should *not* be blocked by strict RTP.

(closes issue ASTERISK-20415)
Reported by: Michele Cicciotti
patches:
  uploaded by Joshua Colp (trunk r369817)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373702 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 19:32:46 +00:00
Kinsey Moore
bc716c7acd "show" completion option for "queue" shouldn't appear twice
When tab-completing CLI commands starting with "queue", "show" appeared
twice in the list due to the way that Asterisk's tab completion
functions and the order in which the commands were registered. The
registration order has been altered to resolve this issue.

(closes issue AST-940)
Reported-by: Steve Pitts


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373666 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 18:15:06 +00:00
Terry Wilson
6f943721f1 Properly handle UAC/UAS roles for SIP session timers
The SIP session timer mechanism contains a mandatory 'refresher' parameter
(included in the Session-Expires header) which is used in the session timer
offer/answer signaling within a SIP Invite dialog. It looks like asterisk is
interpreting the uac resp. uas role only as the initial role of client and
server (caller is uac, callee is uas). The standard rfc 4028 however assigns
the client role to the ((RE)-Invite) requester, the server role to the
((RE)-Invite) responder.

This patch has Asterisk track the actual refresher as "us" or "them" as opposed
to relying on just the configured "uas" or "uac" properties.

(closes issue AST-922)
Reported by: Thomas Airmont

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373652 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 17:21:19 +00:00
Richard Mudgett
1e43c3bada Fix valgrind found memcpy issues in codec_ilbc.
Valgrind found codec_ilbc using memcpy instead of memmove for overlapping
memory blocks.

(issue ASTERISK-19890)
(closes issue ASTERISK-20231)
Reported by: Walter Doekes
Patches:
      ASTERISK-20231.patch (license #5674) patch uploaded by Walter Doekes


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373640 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 17:18:38 +00:00
Richard Mudgett
f5a131c23b Make rebuild GSM, ilbc, or lpc10 codecs if the respective sources change.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373618 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 16:17:06 +00:00
Jonathan Rose
fdd5c7fb73 chan_sip: Set Quality of Service for video rtp instance
(closes issue ASTERISK-20201)
Reported by: ddkprog
Patches:
    chan_sip.c.diff uploaded by ddkprog (license 6008)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373617 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 16:15:12 +00:00
Kinsey Moore
b368d7882f Fix documentation for default username in res_odbc
This was previously stated to be "root", but is actually the name of
the context if unspecified.

(closes issue ASTERISK-20258)
Reported by: Stefan x

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373578 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 13:27:43 +00:00
Joshua Colp
10434240e7 Fix an issue where a caller to ast_write on a MulticastRTP channel would determine it failed when in reality it did not.
When sending RTP packets via multicast the amount of data sent is stored in a variable and returned
from the write function. This is incorrect as any non-zero value returned is considered a failure while
a return value of 0 is success. For callers (such as ast_streamfile) that checked the return value
they would have considered it a failure when in reality nothing went wrong and it was actually a success.

The write function for the multicast RTP engine now returns -1 on failure and 0 on success, as it should.

(closes issue ASTERISK-17254)
Reported by: wybecom


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373550 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 11:58:43 +00:00
Joshua Colp
c9145b15e9 Add missing checks that I neglected. The SIP technology and SIP info technology should be considered equal.
(closes issue ASTERISK-20409)
Reported by: michele cicciotti privatewave


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373532 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25 00:09:46 +00:00
Matthew Jordan
1a77008a0c Revert change to res_rtp_asterisk committed in r373236 (1.8)
The change committed in r373236 attempted to account for endpoints that
increased their RTP timestamp in DTMF end of event re-transmissions.  This
change attempted to make Asterisk continue to work with endpoints that
failed to follow the RFC while maintaining the fix that allowed for out of
order DTMF to be handled.  Unfortunately, there is no free lunch, and this
patch broke any system that sent DTMF immediately after an RTP session was
established or when an SSRC is updated.  As such, that patch is being
reverted for the previous behavior.

Endpoints that erroneously increase the RTP timestamp in DTMF end of event
packets will not work properly with Asterisk.

(issue ASTERISK-20424)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373504 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24 22:15:25 +00:00
Richard Mudgett
00c9a02a93 Be consistent, send From: "Anonymous" <sip:anonymous@anonymous.invalid>
When setting CALLERID(pres)=unavailable in the dialplan, the From header
in the SIP message contains "Anonymous" <sip:Anonymous@anonymous.invalid>.
For consistency, Asterisk should use a lowercase a in the userpart of the
URI.

* Make the From header use a lowercase A in the userpart of the anonymous
URI.

(closes issue ASTERISK-19838)
Reported by: Antti Yrjola
Patches:
      chan_sip_patch_ASTERISK-19838.patch (license #6383) patch uploaded by Antti Yrjola


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373500 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24 22:09:12 +00:00
Jonathan Rose
1c200ea1b2 func_audiohookinherit: Document some missed sources.
This patch also mentions that AUDIOHOOK_INHERIT can be used to
transfer MixMonitor audiohooks. There is also wiki that addresses
audiohooks and the use of AUDIOHOOK_INHERIT at the following link:
https://wiki.asterisk.org/wiki/display/AST/Audiohooks

(closes issue ASTERISK-18220)
Reported by: Ishfaq Malik



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373467 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24 20:57:28 +00:00
Joshua Colp
d93f9bf7b4 Fix a deadlock caused by a race condition between removing a hint and reloading the dialplan and subscribing to the removed hint.
If conditions were right it was possible for both the PBX core and chan_sip to deadlock by both having a lock that the other
wants. In the case of the PBX core it had the contexts lock and wanted a SIP dialog lock, while in the case of chan_sip it
had the SIP dialog lock and wanted the contexts lock.

This fix unlocks the SIP dialog before getting the extension state so that the other thread will not block on trying to lock
it. Once the extension state is retrieved the SIP dialog is locked again and life carries on.

As the SIP dialog is reference counted it is not possible for it to go away after unlocking.

(closes issue ASTERISK-20437)
Reported by: jhutchins


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373438 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24 19:15:24 +00:00
Richard Mudgett
dfba41a295 Fix potential reentrancy problems in chan_sip.
Asterisk v1.8 and later was not as vulnerable to this issue.

* Made find_call() lock each private as it processes the found dialogs.
(Primary cause of ABE-2876)

* Made the other functions that traverse the dialogs container lock each
private as it examines them.

* Fix race condition in sip_call() if the thread that sent the INVITE is
held up long enough for a response to be processed.  The p->initid for the
INVITE retransmission could be added after it was canceled by the response
processing.

* Made __sip_destroy() clean up resource pointers after freeing.  This is
primarily defensive in case someone has a stale private pointer.

* Removed redundant memset() in reqprep().  The call to init_req() already
does the memset() and is the first reference to req in reqprep().

* Removed useless set of req.method in transmit_invite().  The calls to
initreqprep() and reqprep() have to do this because they memset() the req.

JIRA ABE-2876

..........

Merged -r373423 from https://origsvn.digium.com/svn/asterisk/be/branches/C.3-bier


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373424 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24 15:40:22 +00:00
Jonathan Rose
181319ae13 iax2-provision: Fix improper return on failed cache retrieval
(closes issue ASTERISK-20337)
reported by: John Covert
Patches:
    iax2-provision.c.patch uploaded by John Covert (license 5512)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373342 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-21 19:00:48 +00:00
Jonathan Rose
2faa39b458 app_queue: Make queue reload members and variants of that work
Prior to this patch, 'queue reload members' cli command did not
work at all. This also affects the manager function 'QueueReload'
when supplied with the 'members: yes' field.

(closes issue AST-956)
Reported by: John Bigelow


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373298 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-21 15:01:29 +00:00
Joshua Colp
dde552054a Fix incorrect MeetME conference bridge reference count decrementing and sometimes premature destruction.
When using the 'e' or 'E' option to MeetMe the configured conference bridges are loaded and examined to see
if any are empty. If no conference bridges are empty the caller is prompted to enter the number of one.
This operation left around a pointer to the last created conference bridge still containing participants.
When the caller that was not able to find any empty conference bridge hung up this pointer was disposed of
and the reference count of the conference bridge decremented. If there was only a single participant in the
conference bridge it was ultimately destroyed prematurely.

(closes issue AST-994)
Reported by: John Bigelow


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373242 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-20 19:12:53 +00:00
Matthew Jordan
e832fbef1d When processing RFC 2833 DTMF, accomodate increasing timestamps in End events
While endpoints should not be changing the source timestamp between DTMF event
packets, the fact is there exists those endpoints that do exactly that.  To
work around this, we absorb timestamps within the expected re-transmit period.
Note that this period only affects End of Event packets, so it should not
prevent the detection of new DTMF digits that happen to arrive right on top
of each other.

(closes issue ASTERISK-20424)
Reported by: Vladimir Mikhelson
Tested by: mjordan, Vladimir Mikhelson

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@373236 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-20 18:41:45 +00:00