]> git.ipfire.org Git - thirdparty/asterisk.git/log
thirdparty/asterisk.git
15 years agoPrevent a potential race condition and crash when hanging up a channel by removing...
Matthew Nicholson [Thu, 17 Sep 2009 14:58:39 +0000 (14:58 +0000)] 
Prevent a potential race condition and crash when hanging up a channel by removing the channel from the channel list before begining channel tear down.

This fix may potentially cause problems with CDR backends that access the channel a CDR is associated with via the channel list.  This fix makes the channel unavabile at the time when the CDR backend is invoked.  This has been documented in include/asterisk/cdr.h.

(closes issue #15316)
Reported by: vmarrone
Tested by: mnicholson

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@219136 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoProperly deal with quotes in the arguments of '#exec' includes.
Tilghman Lesher [Wed, 16 Sep 2009 23:21:53 +0000 (23:21 +0000)] 
Properly deal with quotes in the arguments of '#exec' includes.
(closes issue #15583)
 Reported by: pkempgen
 Patches:
       20090726__issue15583.diff.txt uploaded by tilghman (license 14)
       20090726__issue15583-1.4-4.diff.txt uploaded by pkempgen (license 169)
 Tested by: pkempgen

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@219023 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFixes CID pattern matching behavior to mirror that of extension pattern matching.
David Brooks [Wed, 16 Sep 2009 18:00:45 +0000 (18:00 +0000)] 
Fixes CID pattern matching behavior to mirror that of extension pattern matching.

Pattern matching for extensions uses a type of scoring system, giving values for
specificity to each character in the pattern. Unfortunately, this is done character
by character, in order. This does lead to some less specific patterns being first
in line for matching, but it will usually get the job done.

This patch merely brings CID matching to the same level as extension matching.
This patch does not attempt to tackle the problem shared by extension matching.

(closes issue #14708)
Reported by: klaus3000

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218867 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoRemove the IAXy firmware from Asterisk.
Russell Bryant [Wed, 16 Sep 2009 13:33:43 +0000 (13:33 +0000)] 
Remove the IAXy firmware from Asterisk.

The firmware can now be found on downloads.digium.com, where the rest of our
binary downloads live.  This was the last part of our Asterisk tarballs that
was considered non-free by Debian.  :-)

(closes issue #15838)
Reported by: paravoid

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218798 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoIf the user enters the same password as before, don't signal an error when the change...
Tilghman Lesher [Tue, 15 Sep 2009 22:27:41 +0000 (22:27 +0000)] 
If the user enters the same password as before, don't signal an error when the change does nothing.
(closes issue #15492)
 Reported by: cbbs70a
 Patches:
       20090713__issue15492.diff.txt uploaded by tilghman (license 14)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218730 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix small memory leak in handle_init_event by always destroying the pthread
Jeff Peeler [Tue, 15 Sep 2009 16:29:27 +0000 (16:29 +0000)] 
Fix small memory leak in handle_init_event by always destroying the pthread
attr before returning.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218623 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoSend request contact header field with response to registrer queries instead of the...
Matthew Nicholson [Tue, 15 Sep 2009 16:03:54 +0000 (16:03 +0000)] 
Send request contact header field with response to registrer queries instead of the address of record.

(closes issue #14438)
Reported by: ravindrad
Patches:
      regquerypatch uploaded by ravindrad (license 684)
Tested by: ravindrad

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218578 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoEnsure FollowMe sets language in channels it creates.
Tilghman Lesher [Tue, 15 Sep 2009 16:01:17 +0000 (16:01 +0000)] 
Ensure FollowMe sets language in channels it creates.
Also, not in the original bug report, but related fields are accountcode and
musicclass, and the inheritance of datastores.
(closes issue #15372)
 Reported by: Romik
 Patches:
       20090828__issue15372.diff.txt uploaded by tilghman (license 14)
 Tested by: cervajs

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218577 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agorevert accidental commit
Kevin P. Fleming [Tue, 15 Sep 2009 14:57:01 +0000 (14:57 +0000)] 
revert accidental commit

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218498 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoUse proper hostname for downloading sound files.
Kevin P. Fleming [Tue, 15 Sep 2009 14:55:58 +0000 (14:55 +0000)] 
Use proper hostname for downloading sound files.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218497 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix handling of DAHDI_EVENT_REMOVED event to prevent crash in do_monitor.
Jeff Peeler [Mon, 14 Sep 2009 21:47:11 +0000 (21:47 +0000)] 
Fix handling of DAHDI_EVENT_REMOVED event to prevent crash in do_monitor.

After talking to rmudgett about some of his recent iflist locking changes, it
was determined that the only place that would destroy a channel without being
explicitly to do so was in handle_init_event. The loop to walk the interface
list has been modified to wait to destroy the channel until the dahdi_pvt of
the channel to be destroyed is no longer needed.

(closes issue #15378)
Reported by: samy

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218401 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoDon't say "Please try again" if we don't give the user another chance to try again.
Tilghman Lesher [Mon, 14 Sep 2009 19:16:35 +0000 (19:16 +0000)] 
Don't say "Please try again" if we don't give the user another chance to try again.
(issue #15055, SWP-129)
 Reported by: jthurman

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218331 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoEnsure we don't pickup ourselves when doing pickup by exten.
Matthew Nicholson [Mon, 14 Sep 2009 14:53:57 +0000 (14:53 +0000)] 
Ensure we don't pickup ourselves when doing pickup by exten.

(closes issue #15100)
Reported by: lmsteffan
Patches:
      (modified) pickup.patch uploaded by lmsteffan (license 779)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@218223 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoDon't ring another channel, if there's not enough time for a queue member to answer.
Tilghman Lesher [Thu, 10 Sep 2009 23:52:22 +0000 (23:52 +0000)] 
Don't ring another channel, if there's not enough time for a queue member to answer.
(Fixes AST-228)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217989 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoBackport realtime fix to 1.4
Tilghman Lesher [Thu, 10 Sep 2009 23:15:21 +0000 (23:15 +0000)] 
Backport realtime fix to 1.4

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217917 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoIAX2 encryption regression
David Vossel [Thu, 10 Sep 2009 21:06:07 +0000 (21:06 +0000)] 
IAX2 encryption regression

The IAX2 Call Token security patch inadvertently broke the use of
encryption due to the reorganization of code in the socket_process()
function.  When encryption is used, an incoming full frame must first
be decrypted before the information elements can be parsed.  The
security release mistakenly moved IE parsing before decryption in
order to process the new Call Token IE.  To resolve this, decryption
of full frames is once again done before looking into the frame.  This
involves searching for an existing callno, checking the pvt to see if
encryption is turned on, and decrypting the packet before the internal
fields of the full frame are accessed.

associated with AST-2009-006

(closes issue #15834)
Reported by: karesmakro
Patches:
      iax2_encryption_fix_1.4.diff uploaded by dvossel (license 671)
Tested by: dvossel, karesmakro

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217806 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoReinstate muted that was removed by mistake.
Olle Johansson [Thu, 10 Sep 2009 19:52:19 +0000 (19:52 +0000)] 
Reinstate muted that was removed by mistake.

muted doesn't compile any more on os/x, so I have to disable it in order to testcompile other code...

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217735 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoRemove harmful code that causes endless loops.
Olle Johansson [Thu, 10 Sep 2009 19:07:24 +0000 (19:07 +0000)] 
Remove harmful code that causes endless loops.
Remove code that causes loops in registrations.

We have agreed that the patch that this code was part of was bad. I am ripping out the code that causes
the issue. putnopvut needs to check the rest of the patch, if it needs to be changed as well.

This solves the issue reported in #15540, but needs more work before we close it (as described above).

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217668 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoWhen MOH is playing on the channel, announcements sent through the conference are...
Tilghman Lesher [Tue, 8 Sep 2009 20:01:45 +0000 (20:01 +0000)] 
When MOH is playing on the channel, announcements sent through the conference are not heard.
(closes issue #14588)
 Reported by: voipas
 Patches:
       20090716__issue14588__2.diff.txt uploaded by tilghman (license 14)
 Tested by: lmadsen, twisted, tilghman

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@217156 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agomake asterisk compile under devmode with DEBUG_THREADS enabled on OpenBSD
Michiel van Baak [Fri, 4 Sep 2009 13:56:10 +0000 (13:56 +0000)] 
make asterisk compile under devmode with DEBUG_THREADS enabled on OpenBSD

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216435 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agomake chan_sip compile under devmode again
Michiel van Baak [Fri, 4 Sep 2009 13:53:09 +0000 (13:53 +0000)] 
make chan_sip compile under devmode again

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216432 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMake apps send PROGRESS control frame for early media and fix too early media issue...
Olle Johansson [Fri, 4 Sep 2009 13:45:48 +0000 (13:45 +0000)] 
Make apps send PROGRESS control frame for early media and fix too early media issue in SIP

The issue at hand is that some legacy (dying) PBX systems send empty media frames on PRI
links *before* any call progress. The SIP channel receives these frames and by default
signals 183 Session progress and starts sending media. This will cause phones to
play silence and ignore the later 180 ringing message. A bad user experience.

The fix is twofold:
- We discovered that asterisk apps that support early media ("noanswer") did not send
  any PROGRESS frame to indicate early media. Fixed.
- We introduce a setting in chan_sip so that users can disable any relay of media frames
  before the outbound channel actually indicates any sort of call progress.
  In 1.4, 1.6.0 and 1.6.1, this will be disabled for backward compatibility. In later versions
  of Asterisk, this will be enabled. We don't assume that it will change your Asterisk
  phone experience - only for the better.

We encourage third-party application developers to make sure that if they have applications
that wants to send early media, add a PROGRESS control frame transmission to make sure that
all channel drivers actually will start sending early media. This has not been the default
in Asterisk previous to this patch, so if you got inspiration from our code, you need to
update accordingly. Sorry for the trouble and thanks for your support.

This code has been running for a few months in a large scale installation (over 250
servers with PRI and/or BRI links to old PBX systems).
That's no proof that this is an excellent patch, but, well, it's tested :-)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216430 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMake sure 'start' is always initialized.
Michiel van Baak [Fri, 4 Sep 2009 13:16:29 +0000 (13:16 +0000)] 
Make sure 'start' is always initialized.

This is the same as rev 216222 in trunk but 1.4 is affected as well

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216369 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMerged revisions 216262 via svnmerge from
Russell Bryant [Fri, 4 Sep 2009 10:48:00 +0000 (10:48 +0000)] 
Merged revisions 216262 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
  r216262 | russell | 2009-09-04 05:47:37 -0500 (Fri, 04 Sep 2009) | 2 lines

  Add a plain text version of the IAX2 security document.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216263 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoBlocked revisions 216087 via svnmerge
Russell Bryant [Thu, 3 Sep 2009 19:37:19 +0000 (19:37 +0000)] 
Blocked revisions 216087 via svnmerge

........
  r216087 | russell | 2009-09-03 14:37:05 -0500 (Thu, 03 Sep 2009) | 2 lines

  Fix a typo.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216089 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMerged revisions 216080 via svnmerge from
Russell Bryant [Thu, 3 Sep 2009 19:36:46 +0000 (19:36 +0000)] 
Merged revisions 216080 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
  r216080 | russell | 2009-09-03 14:35:23 -0500 (Thu, 03 Sep 2009) | 2 lines

  Add a note about IAX2 to UPGRADE.txt.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216085 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMerged revisions 216005 via svnmerge from
Russell Bryant [Thu, 3 Sep 2009 18:44:58 +0000 (18:44 +0000)] 
Merged revisions 216005 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
  r216005 | russell | 2009-09-03 13:42:24 -0500 (Thu, 03 Sep 2009) | 2 lines

  Add IAX2 security document related to AST-2009-006.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216008 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMerge code associated with AST-2009-006
David Vossel [Thu, 3 Sep 2009 18:32:32 +0000 (18:32 +0000)] 
Merge code associated with AST-2009-006

(closes issue #12912)
Reported by: rathaus
Tested by: tilghman, russell, dvossel, dbrooks

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@216000 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoRe-send non-100 provisional responses to prevent cancellation
Terry Wilson [Wed, 2 Sep 2009 21:41:22 +0000 (21:41 +0000)] 
Re-send non-100 provisional responses to prevent cancellation

From section 13.3.1.1 of RFC 3261:

   If the UAS desires an extended period of time to answer the INVITE,
   it will need to ask for an "extension" in order to prevent proxies
   from canceling the transaction. A proxy has the option of canceling
   a transaction when there is a gap of 3 minutes between responses in a
   transaction. To prevent cancellation, the UAS MUST send a non-100
   provisional response at every minute, to handle the possibility of
   lost provisional responses.

(closes issue #11157)
Reported by: rjain
Tested by: twilson

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@215682 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoUse strrchr() so SoftHangup will correctly truncate multi-hyphen channel names
Dwayne M. Hubbard [Tue, 1 Sep 2009 23:04:52 +0000 (23:04 +0000)] 
Use strrchr() so SoftHangup will correctly truncate multi-hyphen channel names

In general channel names are in the form Foo/Bar-Z, but the channel name
could have multiple hyphens and look like Foo/B-a-r-Z.  Use strrchr to
truncate the channel name at the last hyphen.

(closes issue #15810)
Reported by: dhubbard
Patches:
      dw-softhangup-1.4.patch uploaded by dhubbard (license 733)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@215270 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoAlso unlock the "other" channel, when returning, due to glare.
Tilghman Lesher [Mon, 31 Aug 2009 16:16:52 +0000 (16:16 +0000)] 
Also unlock the "other" channel, when returning, due to glare.
(closes issue #15787)
 Reported by: tim_ringenbach
 Patches:
       chan_local.diff uploaded by tim ringenbach (license 540)
 Tested by: tim_ringenbach

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214940 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoModify comment to be a bit more accurate.
Tilghman Lesher [Fri, 28 Aug 2009 20:13:32 +0000 (20:13 +0000)] 
Modify comment to be a bit more accurate.
We have kept this comment around long enough, that it's pretty clear that we're
keeping the code, because changing the code would require a pretty fundamental
architectural shift.  We've also taken criticism in some quarters, because it
was believed that it was referring to the code being nasty.  No, the code isn't
nasty, just the operation itself is rather odd.  Fixed for eternity (probably
not).

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214701 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoUse autoconf to detect libcurl, as this enables cross-compilation checks, something...
Tilghman Lesher [Thu, 27 Aug 2009 21:45:34 +0000 (21:45 +0000)] 
Use autoconf to detect libcurl, as this enables cross-compilation checks, something we didn't allow before.
(closes issue #15714)
 Reported by: pprindeville
 Patches:
       20090813__issue15714.diff.txt uploaded by tilghman (license 14)
 Tested by: pprindeville

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214517 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoOne more build system change, to make the descriptions look better, if we have better...
Tilghman Lesher [Thu, 27 Aug 2009 16:53:58 +0000 (16:53 +0000)] 
One more build system change, to make the descriptions look better, if we have better information.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214436 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMake autoheader descriptions render correctly in our autoconfig.h file.
Tilghman Lesher [Thu, 27 Aug 2009 16:03:50 +0000 (16:03 +0000)] 
Make autoheader descriptions render correctly in our autoconfig.h file.
(Figured out while working with issue #14906)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214357 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoast_write() ignores ast_audiohook_write() results
David Vossel [Wed, 26 Aug 2009 16:36:42 +0000 (16:36 +0000)] 
ast_write() ignores ast_audiohook_write() results

In ast_write(), if a channel has a list of audiohooks, those
lists are written to and the resulting frame is what ast_write()
should continue with.  The problem was the returned audiohook frame
was not being handled at all, and the original frame passed
into it did not contain the mixed audio, so essentially audio
was being lost.  One result of this was chan_spy's whisper
mode no longer worked.  To complicate the issue, frames
passed into ast_write may either be a single frame, or a list
of frames.  So, as the list of frames is processed in the
audiohook_write, the returned frames had to be added to a new
list.

(closes issue #15660)
Reported by: corruptor
Tested by: dvossel

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214194 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoI should always compile before committing...
Tilghman Lesher [Tue, 25 Aug 2009 19:28:42 +0000 (19:28 +0000)] 
I should always compile before committing...

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214069 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix pronunciation of German dates.
Tilghman Lesher [Tue, 25 Aug 2009 19:26:50 +0000 (19:26 +0000)] 
Fix pronunciation of German dates.
(closes issue #15273)
 Reported by: Benjamin Kluck
 Patches:
       say_c.patch uploaded by Benjamin Kluck (license 803)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@214068 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoImprove error message by informing user exactly which function is missing a parethesis.
Tilghman Lesher [Tue, 25 Aug 2009 06:34:44 +0000 (06:34 +0000)] 
Improve error message by informing user exactly which function is missing a parethesis.
(closes issue #15242)
 Reported by: Nick_Lewis
 Patches:
       pbx.c-funcparenthesis.patch2 uploaded by dbrooks (license 790)
       pbx.c-funcparenthesis-1.4.diff uploaded by loloski (license 68)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213970 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoUse the default runlevels for Debian derivatives, instead of making up our own.
Tilghman Lesher [Tue, 25 Aug 2009 02:40:22 +0000 (02:40 +0000)] 
Use the default runlevels for Debian derivatives, instead of making up our own.
(closes issue #14730)
 Reported by: pkempgen

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213899 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoEnsure that T.38 INVITEs generated by Asterisk properly result in T.38 being enabled.
Kevin P. Fleming [Fri, 21 Aug 2009 20:23:45 +0000 (20:23 +0000)] 
Ensure that T.38 INVITEs generated by Asterisk properly result in T.38 being enabled.

(closes issue #15373)
Reported by: dcolombo
Patches:
      chan_sip.patch uploaded by mbrancaleoni (license 342)
Tested by: dcolombo, mbrancaleoni

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213631 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoPermit DEBUG_FD_LEAKS to be used with C++ source files.
Tilghman Lesher [Fri, 21 Aug 2009 16:52:53 +0000 (16:52 +0000)] 
Permit DEBUG_FD_LEAKS to be used with C++ source files.
(closes issue #15698)
 Reported by: slavon
 Patches:
       20090817__issue15698.diff.txt uploaded by tilghman (license 14)
 Tested by: slavon, tilghman

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213559 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoClarify queues.conf comments to specify that variables should be set in the dialplan.
Jason Parker [Fri, 21 Aug 2009 16:03:21 +0000 (16:03 +0000)] 
Clarify queues.conf comments to specify that variables should be set in the dialplan.

(closes issue #15755)
Reported by: trendboy

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213493 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix a crash by checking the proper pointer for validity before deferencing it.
Matthew Nicholson [Thu, 20 Aug 2009 20:33:07 +0000 (20:33 +0000)] 
Fix a crash by checking the proper pointer for validity before deferencing it.

(closes issue #15751)
Reported by: atis
Patches:
      ast_bridge_call_peer_cdr.patch uploaded by atis (license 242)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213339 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoMake all the symbols for the C-client callbacks global
Jeff Peeler [Thu, 20 Aug 2009 19:53:34 +0000 (19:53 +0000)] 
Make all the symbols for the C-client callbacks global

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213283 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFixes memory leak caused by incorrectly freeing mixmonitor
David Vossel [Wed, 19 Aug 2009 21:18:37 +0000 (21:18 +0000)] 
Fixes memory leak caused by incorrectly freeing mixmonitor

(closes issue #15699)
Reported by: edantie
Patches:
      mixmonitor.patch uploaded by edantie (license 862)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@213103 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoConvert this branch to Opsound music-on-hold.
Kevin P. Fleming [Tue, 18 Aug 2009 20:26:53 +0000 (20:26 +0000)] 
Convert this branch to Opsound music-on-hold.

For more details:
http://blogs.digium.com/2009/08/18/asterisk-music-on-hold-changes/

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@212913 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoDelay the creation of temporary files until we have a valid manager command to handle.
Sean Bright [Tue, 18 Aug 2009 16:36:00 +0000 (16:36 +0000)] 
Delay the creation of temporary files until we have a valid manager command to handle.

Without this patch, asterisk creates a temporary file before determining if the
specified command is valid.  If invalid, we weren't properly cleaning up the file.

(closes issue #15730)
Reported by: zmehmood
Patches:
      M15730.diff uploaded by junky (license 177)
Tested by: zmehmood

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@212763 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoRemoved some deadwood and added some doxygen comments.
Richard Mudgett [Tue, 18 Aug 2009 16:00:56 +0000 (16:00 +0000)] 
Removed some deadwood and added some doxygen comments.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@212727 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix segfault when reloading chan_misdn.
Jeff Peeler [Mon, 17 Aug 2009 16:34:56 +0000 (16:34 +0000)] 
Fix segfault when reloading chan_misdn.

If more ports were specified than configured in misdn.conf a reload would crash
asterisk. The problem was the unconfigured port was using data from the
previously configured port. When the data for an unconfigured port was freed a
crash would result from the double free.

(closes issue #12113)
Reported by: agupta
Patches:
      bug12113.patch uploaded by jpeeler (license 325)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@212498 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoFix uninitialized variable.
Richard Mudgett [Mon, 17 Aug 2009 15:36:28 +0000 (15:36 +0000)] 
Fix uninitialized variable.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@212430 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoThis patch adds additional checking when generating queue log TRANSFER events.
Matthew Nicholson [Wed, 12 Aug 2009 23:04:02 +0000 (23:04 +0000)] 
This patch adds additional checking when generating queue log TRANSFER events.

The additional checks prevent generation of false TRANSFER events in certain situations.

(closes issue #14536)
Reported by: aragon
Patches:
      queue-log-xfer-fix1.diff uploaded by mnicholson (license 96)
Tested by: aragon, mnicholson

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211953 65c4cc65-6c06-0410-ace0-fbb531ad65f3

15 years agoBackport fix so that outbound CANCEL requests have same branch as challenged INVITEs.
Mark Michelson [Wed, 12 Aug 2009 18:46:09 +0000 (18:46 +0000)] 
Backport fix so that outbound CANCEL requests have same branch as challenged INVITEs.

There already was code present to be sure that a CANCEL will contain the same branch-id
as the INVITE it is cancelling. However, for INVITES which are challenged downstream,
this mechanism did not work properly. Now this is taken care of.

This is a backport of a fix already present in all 1.6.X branches and in trunk. It also
fixes ABE-1907.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211807 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoConversion specifiers, not format specifiers
Tilghman Lesher [Mon, 10 Aug 2009 19:48:48 +0000 (19:48 +0000)] 
Conversion specifiers, not format specifiers

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211583 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoAST-2009-005
Tilghman Lesher [Mon, 10 Aug 2009 19:15:57 +0000 (19:15 +0000)] 
AST-2009-005

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211528 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoSmall oops. Clear the flags which have been checked.
Tilghman Lesher [Sun, 9 Aug 2009 15:41:01 +0000 (15:41 +0000)] 
Small oops.  Clear the flags which have been checked.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211274 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoResolve a deadlock involving app_chanspy and masquerades.
Russell Bryant [Fri, 7 Aug 2009 20:11:31 +0000 (20:11 +0000)] 
Resolve a deadlock involving app_chanspy and masquerades.

(ABE-1936)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211112 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoQUEUE_MEMBER_LIST _really_ wants the interface name, not the membername.
Tilghman Lesher [Fri, 7 Aug 2009 18:16:28 +0000 (18:16 +0000)] 
QUEUE_MEMBER_LIST _really_ wants the interface name, not the membername.

This is a partial revert of revision 82590, which was an attempted cleanup,
but in reality, it broke QUEUE_MEMBER_LIST, which has always been intended
as a method by which component interfaces could be queried from the queue.
Membername isn't useful here, because that field cannot be used to obtain
further information about the member.  See the documentation on
QUEUE_MEMBER_LIST, RemoveQueueMember, QUEUE_MEMBER_PENALTY, and the various
AMI commands which take a member argument for further justification.
(closes issue #15664)
 Reported by: rain
 Patches:
       app_queue-queue_member_list.diff uploaded by rain (license 327)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@211038 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoBecause channel information can be accessed outside of the channel thread, we must...
Tilghman Lesher [Thu, 6 Aug 2009 21:45:01 +0000 (21:45 +0000)] 
Because channel information can be accessed outside of the channel thread, we must lock the channel prior to modifying it.
(closes issue #15397)
 Reported by: caspy
 Patches:
       20090714__issue15397.diff.txt uploaded by tilghman (license 14)
 Tested by: caspy

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210913 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoDialplan starts execution before the channel setup is complete.
Richard Mudgett [Wed, 5 Aug 2009 19:18:56 +0000 (19:18 +0000)] 
Dialplan starts execution before the channel setup is complete.

*  Issue 15655: For the case where dialing is complete for an incoming
call, dahdi_new() was asked to start the PBX and then the code set more
channel variables.  If the dialplan hungup before these channel variables
got set, asterisk would likely crash.
*  Fixed potential for overlap incoming call to erroneously set channel
variables as global dialplan variables if the ast_channel structure failed
to get allocated.
*  Added missing set of CALLINGSUBADDR in the dialing is complete case.

(closes issue #15655)
Reported by: alecdavis

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210575 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoUpdate imapstorage.txt documentation.
Leif Madsen [Wed, 5 Aug 2009 18:46:21 +0000 (18:46 +0000)] 
Update imapstorage.txt documentation.
Updated the imapstorage.txt documentation to reflect that issues with
c-client versions older than 2007 seem to cause crashing issues that
are not seen with more recent versions. Documentation has been updated
to reflect this.

(closes issue #14496)
Reported by: vbcrlfuser
Patches:
      __20090727-imap-documentation-patch.txt uploaded by lmadsen (license 10)
Tested by: lmadsen, mmichelson, dbrooks

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210563 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoEliminate spurious compiler warnings from system headers on *BSD platforms.
Kevin P. Fleming [Tue, 4 Aug 2009 14:51:39 +0000 (14:51 +0000)] 
Eliminate spurious compiler warnings from system headers on *BSD platforms.

Ensure that system headers located in /usr/local/include are actually treated
as system headers by the compiler, and not as local headers which are subject
to warnings from the -Wundef compiler option and others.

(closes issue #15606)
Reported by: mvanbaak

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210237 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFixes dialplan wildcard extension taking precedence over call pickup code.
David Brooks [Mon, 3 Aug 2009 16:15:20 +0000 (16:15 +0000)] 
Fixes dialplan wildcard extension taking precedence over call pickup code.

Prior to this patch, a wildcard extension in the dialplan (for example, _*.) would take
precedence over picking up a call in the channel's pickup group. This patch simply moves
the block of code handling pickup group matching to above the extension matching code.

(closes issue #14735)
Reported by: stevedavies

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210067 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoReverting index() fix, applying a different methodology, based upon developer discuss...
Tilghman Lesher [Mon, 3 Aug 2009 16:11:29 +0000 (16:11 +0000)] 
Reverting index() fix, applying a different methodology, based upon developer discussions.
(related to issue #15639)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210066 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoHelps if we export the index() function.
Tilghman Lesher [Mon, 3 Aug 2009 15:42:10 +0000 (15:42 +0000)] 
Helps if we export the index() function.
(Related to issue #15639)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210065 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoApparently, some platforms don't have the index() function.
Tilghman Lesher [Mon, 3 Aug 2009 15:39:41 +0000 (15:39 +0000)] 
Apparently, some platforms don't have the index() function.
(closes issue #15639)
 Reported by: nmav

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@210064 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoResolve a valgrind warning about a read from uninitialized memory.
Russell Bryant [Sat, 1 Aug 2009 11:27:25 +0000 (11:27 +0000)] 
Resolve a valgrind warning about a read from uninitialized memory.

(issue #15396)
Reported by: aragon

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@209879 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoModify how Playtones() is used in Milliwatt() to resolve gain issue.
Russell Bryant [Sat, 1 Aug 2009 10:59:05 +0000 (10:59 +0000)] 
Modify how Playtones() is used in Milliwatt() to resolve gain issue.

When Milliwatt() was changed internally to use Playtones() so that the proper
tone was used, it introduced a drop in gain in the output signal.  So, use
the playtones API directly and specify a volume argument such that the output
matches the gain of the original Milliwatt() code.

(closes issue #15386)
Reported by: rue_mohr
Patches:
      issue_15386.rev2.diff uploaded by russell (license 2)
Tested by: rue_mohr

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@209838 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoMinor changes inspired by testing with latest GCC.
Kevin P. Fleming [Sat, 1 Aug 2009 00:52:00 +0000 (00:52 +0000)] 
Minor changes inspired by testing with latest GCC.

The latest GCC (what will become 4.5.x) has a few new warnings, that in these
cases found some either downright buggy code, or at least seriously poorly
designed code that could be improved.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@209759 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoPublish French extra sounds
Tilghman Lesher [Tue, 28 Jul 2009 00:12:03 +0000 (00:12 +0000)] 
Publish French extra sounds

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@209315 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoAllow for UDPTL to use only even-numbered ports if desired.
Mark Michelson [Mon, 27 Jul 2009 17:44:06 +0000 (17:44 +0000)] 
Allow for UDPTL to use only even-numbered ports if desired.

There are some VoIP providers out there that will not accept SDP
offers with odd numbered UDPTL ports. While it is my personal opinion
that these VoIP providers are misinterpreting RFC 2327, it really is
not a big deal to play along with their silly little games. Of course,
since restricting UDPTL ports to only even numbers reduces the range
of available ports by half, so the option to use only even port numbers
is off by default. A user can enable the behavior by setting
use_even_ports=yes in udptl.conf.

(closes issue #15182)
Reported by: CGMChris
Patches:
      15182.patch uploaded by mmichelson (license 60)
Tested by: CGMChris

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@209131 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agobackport rev 205532 from trunk:
Michiel van Baak [Mon, 27 Jul 2009 09:56:13 +0000 (09:56 +0000)] 
backport rev 205532 from trunk:

pthread_self returns a pthread_t which is not an unsigned int on all
pthread implementations. Casting it to an unsigned int fixes compiler warnings.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208990 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFix logic errors from 208746
Jeff Peeler [Mon, 27 Jul 2009 01:18:31 +0000 (01:18 +0000)] 
Fix logic errors from 208746

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208923 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFix compiling under dev-mode with gcc 4.4.0.
Jeff Peeler [Sat, 25 Jul 2009 06:19:50 +0000 (06:19 +0000)] 
Fix compiling under dev-mode with gcc 4.4.0.

Mostly trivial changes, but I did not know of any other way to fix the
"dereferencing type-punned pointer will break strict-aliasing rules" error
without creating a tmp variable in chan_skinny.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208746 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoDon't impose an arbitrary limit on member lines in queues.conf
Mark Michelson [Fri, 24 Jul 2009 19:24:28 +0000 (19:24 +0000)] 
Don't impose an arbitrary limit on member lines in queues.conf

I know what some of you are thinking: "UGH! Mark, why are you using
ast_strdup and ast_free for the string when you can just use ast_strdupa
and let the memory free itself?! Have the bats been chewing on your brain
again?"

Based on past experiences, I don't like using ast_strdupa inside a loop.
It's a good way to potentially exhaust stack space. Also, since this only
happens when reloading queues, I don't think that heap allocations and
frees are going to be a huge problem.

(closes issue #15559)
Reported by: amorsen

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208622 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoDo not log an ERROR if autoservice_stop() returns -1.
Russell Bryant [Fri, 24 Jul 2009 18:38:24 +0000 (18:38 +0000)] 
Do not log an ERROR if autoservice_stop() returns -1.

This does not indicate an error.  A return of -1 just means that the channel
has been hung up.

(reported in #asterisk-dev)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208592 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoOnly send a BYE when hanging up a channel that is up.
Mark Michelson [Fri, 24 Jul 2009 18:26:50 +0000 (18:26 +0000)] 
Only send a BYE when hanging up a channel that is up.

For cases where Asterisk sends an INVITE and receives a non 2XX final
response, Asterisk would follow the INVITE transaction by immediately
sending a BYE, which was unnecessary.

(closes issue #14575)
Reported by: chris-mac

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208587 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFix a problem where a 491 response could be sent out of dialog.
Mark Michelson [Thu, 23 Jul 2009 19:24:21 +0000 (19:24 +0000)] 
Fix a problem where a 491 response could be sent out of dialog.

This generalizes the fix for issue 13849. The initial fix corrected the
problem that Asterisk would reply with a 491 if a reinvite were received
from an endpoint and we had not yet received an ACK from that endpoint
for the initial INVITE it had sent us. This expansion also allows Asterisk
to appropriately handle an INVITE with authorization credentials if Asterisk
had not received an ACK from the previous transaction in which Asterisk had
responded to an unauthorized INVITE with a 407.

(closes issue #14239)
Reported by: klaus3000
Patches:
      14239.patch uploaded by mmichelson (license 60)
Tested by: klaus3000

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208386 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoOnly set the priindication setting when not performing a reload
Jeff Peeler [Thu, 23 Jul 2009 19:19:53 +0000 (19:19 +0000)] 
Only set the priindication setting when not performing a reload

(closes issue #14696)
Reported by: fdecher

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208380 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoRemove inaccurate XXX comment.
Mark Michelson [Thu, 23 Jul 2009 16:29:18 +0000 (16:29 +0000)] 
Remove inaccurate XXX comment.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208312 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoProperly handle 183 responses which do not contain an SDP.
Mark Michelson [Thu, 23 Jul 2009 15:43:07 +0000 (15:43 +0000)] 
Properly handle 183 responses which do not contain an SDP.

(closes issue #15442)
Reported by: ffloimair
Patches:
      15442.patch uploaded by mmichelson (license 60)
Tested by: tkarl, ffloimair

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208262 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoExport symbols for functions included in our compatibility headers.
Tilghman Lesher [Wed, 22 Jul 2009 20:23:53 +0000 (20:23 +0000)] 
Export symbols for functions included in our compatibility headers.
(closes issue #15556)
 Reported by: smw1218

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208083 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoForce an error if a blank is passed to QUOTE (because the documentation states the...
Tilghman Lesher [Tue, 21 Jul 2009 22:38:54 +0000 (22:38 +0000)] 
Force an error if a blank is passed to QUOTE (because the documentation states the argument is not optional).
This change makes URIENCODE and QUOTE behave similarly, since the documentation
states that the argument is not optional, for both.
(closes issue #15439)
 Reported by: pkempgen
 Patches:
       20090706__issue15439.diff.txt uploaded by tilghman (license 14)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207945 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoWait for wink before dialing when using E&M wink signaling
Jeff Peeler [Tue, 21 Jul 2009 20:16:55 +0000 (20:16 +0000)] 
Wait for wink before dialing when using E&M wink signaling

There was already code for other signaling types in dahdi_handle_event to
handle dialing if a dial operation dial string was present. Simply add
SIG_EMWINK to the list.

(closes issue #14434)
Reported by: araasch

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207827 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoRevert r207573, this approach could potentially block for an unacceptable
Jeff Peeler [Tue, 21 Jul 2009 17:15:48 +0000 (17:15 +0000)] 
Revert r207573, this approach could potentially block for an unacceptable
amount of time.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207786 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoDocument default timeout for AMI originations.
Mark Michelson [Tue, 21 Jul 2009 14:26:00 +0000 (14:26 +0000)] 
Document default timeout for AMI originations.

AST-224

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207714 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoEnsure that user-provided CFLAGS and LDFLAGS are honored.
Kevin P. Fleming [Tue, 21 Jul 2009 13:04:44 +0000 (13:04 +0000)] 
Ensure that user-provided CFLAGS and LDFLAGS are honored.

This commit changes the build system so that user-provided flags (in ASTCFLAGS
and ASTLDFLAGS) are supplied to the compiler/linker *after* all flags provided
by the build system itself, so that the user can effectively override the
build system's flags if desired. In addition, ASTCFLAGS and ASTLDFLAGS can now
be provided *either* in the environment before running 'make', or as variable
assignments on the 'make' command line. As a result, the use of COPTS and LDOPTS
is no longer necessary, so they are no longer documented, but are still supported
so as not to break existing build systems that supply them when building Asterisk.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207647 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoWait for wink before dialing when using E&M wink signaling
Jeff Peeler [Mon, 20 Jul 2009 23:23:18 +0000 (23:23 +0000)] 
Wait for wink before dialing when using E&M wink signaling

This patch adds a new dahdi_wait function to specifically wait for the wink
event. If the wink is not eventually received the channel is hung up.

(closes issue #14434)
Reported by: araasch
Patches:
      emwinkmod uploaded by araasch (license 693)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207573 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoAnswer video SDP offers properly when videosupport is not enabled.
Mark Michelson [Mon, 20 Jul 2009 19:39:59 +0000 (19:39 +0000)] 
Answer video SDP offers properly when videosupport is not enabled.

Copied from Review board:

In issue 12434, the reporter describes a situation in which audio and video
is offered on the call, but because videosupport is disabled in sip.conf,
Asterisk gives no response at all to the video offer. According to RFC 3264,
all media offers should have a corresponding answer. For offers we do not
intend to actually reply to with meaningful values, we should still reply
with the port for the media stream set to 0.

In this patch, we take note of what types of media have been offered and
save the information on the sip_pvt. The SDP in the response will take into
account whether media was offered. If we are not otherwise going to answer
a media offer, we will insert an appropriate m= line with the port set to 0.

It is important to note that this patch is pretty much a bandage being
applied to a broken bone. The patch *only* helps for situations where video
is offered but videosupport is disabled and when udptl_pt is disabled but
T.38 is offered. Asterisk is not guaranteed to respond to every media offer.
Notable cases are when multiple streams of the same type are offered.
The 2 media stream limit is still present with this patch, too.

In trunk and the 1.6.X branches, things will be a bit different since Asterisk
also supports text in SDPs as well.

(closes issue #12434)
Reported by: mnnojd

Review: https://reviewboard.asterisk.org/r/311
Review: https://reviewboard.asterisk.org/r/313

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207423 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoOnly do the chan->fdno check in ast_read() in a developer build.
Russell Bryant [Mon, 20 Jul 2009 16:26:24 +0000 (16:26 +0000)] 
Only do the chan->fdno check in ast_read() in a developer build.

I changed this check to only happen in a dev-mode build.  I also added a
comment explaining what is going on.  I also made it so that detection of
this situation does not affect ast_read() operation.

(closes issue #14723)
Reported by: seadweller

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207360 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFix format specifier to print out an unsigned long long.
Jeff Peeler [Fri, 17 Jul 2009 19:36:19 +0000 (19:36 +0000)] 
Fix format specifier to print out an unsigned long long.

Yep, it's even ifdefed out code. But it made it to the RR list...

(closes issue #14726)
Reported by: lmadsen

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207155 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoEnhance configuration option for overlapdial allowing direction choice
Jeff Peeler [Fri, 17 Jul 2009 19:13:27 +0000 (19:13 +0000)] 
Enhance configuration option for overlapdial allowing direction choice

Previously overlap dialing could only be turned on or off for both incoming and
outgoing calls. New parameters incoming, outgoing, and both have been added to
allow further control. There is no change in default behavior with these new
options and allows in band DTMF to be accepted in one direction if required.

(closes issue #14471)
Reported by: eboscani

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207092 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agosip option flags handled incorrectly
David Vossel [Fri, 17 Jul 2009 18:00:38 +0000 (18:00 +0000)] 
sip option flags handled incorrectly

(issue #15376)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@207033 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoSIP incorrect From: header information when callpres is prohib
David Vossel [Fri, 17 Jul 2009 16:05:06 +0000 (16:05 +0000)] 
SIP incorrect From: header information when callpres is prohib

Some ITSP make use of the "Anonymous" display name to detect a
requirement to withhold caller id across the PSTN. This does
not work if the display name is "Unknown".

(closes issue #14465)
Reported by: Nick_Lewis
Patches:
      chan_sip.c-callerpres.patch uploaded by Nick (license 657)
      chan_sip.c-callerpres_trunk.patch uploaded by dvossel (license 671)
Tested by: Nick_Lewis, dvossel

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206938 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoerror in iax.conf related IP-based access control
David Vossel [Thu, 16 Jul 2009 21:33:19 +0000 (21:33 +0000)] 
error in iax.conf related IP-based access control

(closes issue #15518)
Reported by: pkempgen

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206872 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoavoid segfault caused by user error
David Vossel [Thu, 16 Jul 2009 21:24:16 +0000 (21:24 +0000)] 
avoid segfault caused by user error

If the CALLERPRES() dialplan function is set to nothing,
a segfault occurs.  This is user error to begin with, but
I'd rather see a cli warning message than have Asterisk
crash on me.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206867 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFix a memory leak.
Tilghman Lesher [Thu, 16 Jul 2009 16:27:35 +0000 (16:27 +0000)] 
Fix a memory leak.
(closes issue #15517)
 Reported by: adomjan
 Patches:
       func_realtime.c-ast_variable_destroy.diff uploaded by adomjan (license 487)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206807 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoMerged revision 206700 from
Richard Mudgett [Wed, 15 Jul 2009 20:44:55 +0000 (20:44 +0000)] 
Merged revision 206700 from
https://origsvn.digium.com/svn/asterisk/be/branches/C.2-...

..........
  Fixed chan_misdn crash because mISDNuser library is not thread safe.

  With Asterisk the mISDNuser library is driven by two threads concurrently:
  1. channels/misdn/isdn_lib.c::manager_event_handler()
  2. channels/misdn/isdn_lib.c::misdn_lib_isdn_event_catcher()

  Calls into the library are done concurrently and recursively from
  isdn_lib.c.

  Both threads can fiddle with the master/child layer3_proc_t lists.  One
  thread may traverse the list when the other interrupts it and then removes
  the list element which the first thread was currently handling.  This is
  exactly what caused the crash.  About 60 calls were needed to a Gigaset
  CX475 before it occurred once.

  This patch adds locking when calling into the mISDNuser library.
  This also fixes some cb_log calls with wrong port parameter.

  JIRA ABE-1913
      Patches: misdn-locking.patch (Modified with mostly cosmetic changes)
..........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206706 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoOnly print debug info in codec_dahdi if we are asking for it.
Sean Bright [Wed, 15 Jul 2009 15:57:51 +0000 (15:57 +0000)] 
Only print debug info in codec_dahdi if we are asking for it.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206635 65c4cc65-6c06-0410-ace0-fbb531ad65f3

16 years agoFixes several call transfer issues with chan_misdn.
Richard Mudgett [Tue, 14 Jul 2009 16:44:47 +0000 (16:44 +0000)] 
Fixes several call transfer issues with chan_misdn.

*  issue #14355 - Crash if attempt to transfer a call to an application.
Masquerade the other pair of the four asterisk channels involved in the
two calls.  The held call already must be a bridged call (not an
applicaton) or it would have been rejected.

*  issue #14692 - Held calls are not automatically cleared after transfer.
Allow the core to initate disconnect of held calls to the ISDN port.  This
also fixes a similar case where the party on hold hangs up before being
transferred or taken off hold.

*  JIRA ABE-1903 - Orphaned held calls left in music-on-hold.
Do not simply block passing the hangup event on held calls to asterisk
core.

*  Fixed to allow held calls to be transferred to ringing calls.
Previously, held calls could only be transferred to connected calls.
*  Eliminated unused call states to simplify hangup code.
*  Eliminated most uses of "holded" because it is not a word.

(closes issue #14355)
(closes issue #14692)
Reported by: sodom
Patches:
      misdn_xfer_v14_r205839.patch uploaded by rmudgett (license 664)
Tested by: rmudgett

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@206487 65c4cc65-6c06-0410-ace0-fbb531ad65f3