Commit Graph

17137 Commits

Author SHA1 Message Date
Mark Michelson
667812ef7a Remove a revision from the trunk-blocked property since it should have been merged instead.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187552 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 19:55:11 +00:00
Jeff Peeler
95760a36c1 Blocked revisions 187491 via svnmerge
........
  r187491 | jpeeler | 2009-04-09 14:10:02 -0500 (Thu, 09 Apr 2009) | 15 lines
  
  Add ability for dialplan execution to continue when caller hangs up.
  
  The F option to app_dial has been modified to accept no parameters and perform
  the above functionality. I don't see anywhere else that is doing function
  overloading, but this really is the best place for this operation because:
  
  - It makes it close to the 'g' option in the argument list which provides
  similar functionality.
  - The existing code to support the current F option provides a very
  convienient location to add this new feature.
  
  (closes issue #12381)
  Reported by: michael-fig
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187492 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 19:10:28 +00:00
Tilghman Lesher
3d7bac20f6 typo
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187490 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 19:03:50 +00:00
Tilghman Lesher
9a69733bc2 Merged revisions 187483 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r187483 | tilghman | 2009-04-09 13:40:01 -0500 (Thu, 09 Apr 2009) | 15 lines
  
  Merged revisions 187428 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r187428 | tilghman | 2009-04-09 13:08:20 -0500 (Thu, 09 Apr 2009) | 8 lines
    
    Race condition between ast_cli_command() and 'module unload' could cause a deadlock.
    Add lock timeouts to avoid this potential deadlock.
    (closes issue #14705)
     Reported by: jamessan
     Patches: 
           20090320__bug14705.diff.txt uploaded by tilghman (license 14)
     Tested by: jamessan
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187485 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 18:52:58 +00:00
Mark Michelson
43036da2b4 Merged revisions 187421,187424 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r187421 | mmichelson | 2009-04-09 12:30:39 -0500 (Thu, 09 Apr 2009) | 21 lines
  
  Fix a crash in res_musiconhold when using cached realtime moh.
  
  The moh_register function links an mohclass and then immediately
  unrefs the class since the container now has a reference. The problem
  with using realtime music on hold is that the class is allocated,
  registered, and started in one fell swoop. The refcounting logic 
  resulted in the count being off by one. The same problem did not
  happen when using a static config because the allocation and registration
  of an mohclass is a separate operation from starting moh. This also did
  not affect non-cached realtime moh because the classes are not registered
  at all.
  
  I also have modified res_musiconhold to use the _t_ variants of the ao2_
  functions so that more info can be gleaned when attempting to trace the
  refcounts. I found this to be incredibly helpful for debugging this issue
  and there's no good reason to remove it.
  
  (closes issue #14661)
  Reported by: sum
........
  r187424 | mmichelson | 2009-04-09 12:34:39 -0500 (Thu, 09 Apr 2009) | 3 lines
  
  Use safe macro practices even though they really aren't necessary.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187425 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 17:37:50 +00:00
Tilghman Lesher
92b4eb8d40 Merged revisions 187363 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r187363 | tilghman | 2009-04-09 11:39:43 -0500 (Thu, 09 Apr 2009) | 10 lines
  
  Merged revisions 187362 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r187362 | tilghman | 2009-04-09 11:38:37 -0500 (Thu, 09 Apr 2009) | 3 lines
    
    Permit zero-length text messages in SIP.
    (Related to an issue posted to the -users list, subject "AEL2, BASE64_DECODE and hexadecimal")
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187364 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 16:40:29 +00:00
Tilghman Lesher
ec49f90f69 Merged revisions 187302 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r187302 | tilghman | 2009-04-08 23:59:05 -0500 (Wed, 08 Apr 2009) | 14 lines
  
  Merged revisions 187300-187301 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r187300 | tilghman | 2009-04-08 23:31:38 -0500 (Wed, 08 Apr 2009) | 3 lines
    
    Add debugging mode for diagnosing file descriptor leaks.
    (Related to issue #14625)
  ........
    r187301 | tilghman | 2009-04-08 23:32:40 -0500 (Wed, 08 Apr 2009) | 2 lines
    
    Oops, missed this file in the last commit.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187304 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 05:16:06 +00:00
Kevin P. Fleming
d9b8b54a9a Blocked revisions 187269 via svnmerge
........
  r187269 | kpfleming | 2009-04-08 22:44:27 -0400 (Wed, 08 Apr 2009) | 5 lines
  
  add a dedicated log channel for modules to be able report security-related events, so that they can be fed into external processes for analysis and possible mitigation efforts
  
  (inspired by this evening's Toronto Asterisk Users Group meeting and previous dicussions amongst various community members)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187270 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-09 02:45:29 +00:00
Jeff Peeler
6a1c421db9 Blocked revisions 187211 via svnmerge
........
  r187211 | jpeeler | 2009-04-08 16:00:39 -0500 (Wed, 08 Apr 2009) | 20 lines
  
  Add timer for features so that backup bridge config can go away
  
  The biggest change done here was elimination of the backup_config for use with
  features. Previously, the bridging code upon detecting a feature would set the
  start time of the bridge to the start time of the feature. Then after the 
  feature had either expired or timed out the start time would be reset to the
  true bridge start time from the backup_config. Now, the time differences are
  calculated with respect to the newly added feature_start_time timeval instead.
  
  There should be no behavior changes from the previous functionality aside from
  the bridge timing being unaffected by either valid or partial feature matches.
  Previously the timing would be increased by the length of time configured for
  featuredigittimeout, which was probably never noticed.
  
  (closes issue #14503)
  Reported by: KNK
  Tested by: jpeeler
  
  Review: http://reviewboard.digium.com/r/179/
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187212 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 21:01:33 +00:00
Mark Michelson
e933d93cab Blocked revisions 187138 via svnmerge
................
  r187138 | mmichelson | 2009-04-08 14:18:10 -0500 (Wed, 08 Apr 2009) | 13 lines
  
  Blocked revisions 187135 via svnmerge
  
  ........
    r187135 | mmichelson | 2009-04-08 14:16:49 -0500 (Wed, 08 Apr 2009) | 8 lines
    
    Fix a crash due to too few arguments to RetryDial.
    
    (closes issue #14852)
    Reported by: junky
    Patches:
          retry_fix.diff uploaded by junky (license 177)
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187141 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 19:18:35 +00:00
Mark Michelson
3145a3c6b1 Merged revisions 187046 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r187046 | mmichelson | 2009-04-08 11:52:20 -0500 (Wed, 08 Apr 2009) | 16 lines
  
  Merged revisions 187045 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r187045 | mmichelson | 2009-04-08 11:52:03 -0500 (Wed, 08 Apr 2009) | 10 lines
    
    Fix a small logical error when loading moh classes.
    
    We were unconditionally incrementing the number of mohclasses
    registered. However, we should actually only increment if the
    call to moh_register was successful.
    
    While this probably has never caused problems, I noticed it
    and decided to fix it anyway.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@187047 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 16:52:52 +00:00
Jason Parker
24ec838bbf That's how tired I was... I read misdn.conf. Should've been MGCP
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186991 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 16:07:13 +00:00
Jason Parker
51affb6e81 Add missing line to CHANGES. Where did it go? Don't know!
Thanks to thehar for reporting this for me.  I noticed this at about 1:00am last night and just wanted to go to bed.

(closes issue #14853)
Reported by: thehar


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186990 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 16:05:58 +00:00
Mark Michelson
82c0c7822e Merged revisions 186985 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186985 | mmichelson | 2009-04-08 10:27:41 -0500 (Wed, 08 Apr 2009) | 30 lines
  
  Merged revisions 186984 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186984 | mmichelson | 2009-04-08 10:26:46 -0500 (Wed, 08 Apr 2009) | 24 lines
    
    Make a couple of changes with regards to a new message printed in ast_read().
    
    "ast_read() called with no recorded file descriptor" is a new message added
    after a bug was discovered. Unfortunately, it seems there are a bunch of places
    that potentially make such calls to ast_read() and trigger this error message
    to be displayed. This commit does two things to help to make this message appear
    less.
    
    First, the message has been downgraded to a debug level message if dev mode is
    not enabled. The message means a lot more to developers than it does to end users,
    and so developers should take an effort to be sure to call ast_read only when
    a channel is ready to be read from. However, since this doesn't actually cause an
    error in operation and is not something a user can easily fix, we should not spam
    their console with these messages.
    
    Second, the message has been moved to after the check for any pending masquerades.
    ast_read() being called with no recorded file descriptor should not interfere with
    a masquerade taking place.
    
    This could be seen as a simple way of resolving issue #14723. However, I still want
    to try to clear out the existing ways of triggering this message, since I feel that
    would be a better resolution for the issue.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186986 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 15:28:22 +00:00
Mark Michelson
4ce04d6865 Merged revisions 186842 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186842 | mmichelson | 2009-04-07 19:09:28 -0500 (Tue, 07 Apr 2009) | 14 lines
  
  Merged revisions 186841 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186841 | mmichelson | 2009-04-07 19:09:04 -0500 (Tue, 07 Apr 2009) | 8 lines
    
    Fix a few typos of the word "frequency."
    
    (closes issue #14842)
    Reported by: jvandal
    Patches:
          frequency-typo.diff uploaded by jvandal (license 413)
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186843 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 00:09:54 +00:00
Mark Michelson
f30f904099 Merged revisions 186837 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r186837 | mmichelson | 2009-04-07 19:01:49 -0500 (Tue, 07 Apr 2009) | 7 lines
  
  Fix bad merge from fix for issue 13867.
  
  (closes issue #14686)
  Reported by: davidw
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186838 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-08 00:02:19 +00:00
Mark Michelson
d3b10cb2a5 Merged revisions 186833 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186833 | mmichelson | 2009-04-07 18:50:56 -0500 (Tue, 07 Apr 2009) | 15 lines
  
  Merged revisions 186832 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186832 | mmichelson | 2009-04-07 18:49:49 -0500 (Tue, 07 Apr 2009) | 8 lines
    
    Set the AST_FEATURE_WARNING_ACTIVE flag when a p2p bridge returns AST_BRIDGE_RETRY.
    
    Without this flag set, warning sounds will not be properly played to either party
    of the bridge.
    
    (closes issue #14845)
    Reported by: adomjan
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186834 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-07 23:51:25 +00:00
Tilghman Lesher
cfe5f3e0fc Merged revisions 186799 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186799 | tilghman | 2009-04-07 17:23:46 -0500 (Tue, 07 Apr 2009) | 10 lines
  
  Merged revisions 186775 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186775 | tilghman | 2009-04-07 17:16:50 -0500 (Tue, 07 Apr 2009) | 3 lines
    
    Fix Macro documentation to match current (and intended) behavior.
    (See -dev mailing list)
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186805 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-07 22:30:27 +00:00
Mark Michelson
47387bc563 Merged revisions 186720 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186720 | mmichelson | 2009-04-07 15:46:18 -0500 (Tue, 07 Apr 2009) | 12 lines
  
  Merged revisions 186719 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186719 | mmichelson | 2009-04-07 15:43:49 -0500 (Tue, 07 Apr 2009) | 6 lines
    
    Ensure that \r\n is printed after the ActionID in an OriginateResponse.
    
    (closes issue #14847)
    Reported by: kobaz
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186721 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-07 20:49:54 +00:00
Mark Michelson
44550166d8 Blocked revisions 186620 via svnmerge
........
  r186620 | mmichelson | 2009-04-06 11:06:25 -0500 (Mon, 06 Apr 2009) | 3 lines
  
  Silly svn. These files didn't get merged over in the merge of the issue8824 branch.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186621 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-06 16:07:25 +00:00
Mark Michelson
1a2133f46a Blocked revisions 186566 via svnmerge
................
  r186566 | mmichelson | 2009-04-06 08:57:39 -0500 (Mon, 06 Apr 2009) | 8 lines
  
  Blocked revisions 186565 via svnmerge
  
  ........
    r186565 | mmichelson | 2009-04-06 08:54:41 -0500 (Mon, 06 Apr 2009) | 3 lines
    
    Revert commit 186445 because it causes the build to fail when IMAP_STORAGE is used.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186567 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-06 13:58:04 +00:00
Mark Michelson
047e77ad67 Blocked revisions 186525 via svnmerge
........
  r186525 | mmichelson | 2009-04-03 17:41:46 -0500 (Fri, 03 Apr 2009) | 22 lines
  
  This commit introduces COLP/CONP and Redirecting party information into Asterisk.
  
  The channel drivers which have been most heavily tested with these enhancements are
  chan_sip and chan_misdn. Further work is being done to add Q.SIG support and will be
  introduced in a later commit. chan_skinny has code added to it here, but according
  to user pj, the support on chan_skinny is not working as of now. This will be fixed in
  a later commit.
  
  A special thanks goes out to bugtracker user gareth for getting the ball rolling and
  providing the initial support for this work. Without his initial work on this, this would
  not have been nearly as painless as it was.
  
  This functionality has been tested by Digium's product quality department, as well as a
  customer site running thousands of calls every day. In addition, many many many many bugtracker
  users have tested this, too.
  
  (closes issue #8824)
  Reported by: gareth
  
  Review: http://reviewboard.digium.com/r/201
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186526 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 22:43:19 +00:00
Mark Michelson
0af241cd79 Remove an invalid call to free memory.
A bad merge from trunk to 1.6.0 meant freeing memory that
should not be freed. In trunk, pkt->data is an ast_str, but
in 1.6.0, it is allocated in the same chunk of memory as the
sip_pkt. This only affects 1.6.0.

(closes issue #14819)
Reported by: cwolff09



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186517 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 21:27:52 +00:00
Kevin P. Fleming
01cbad2bd6 Merged revisions 186461 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186461 | kpfleming | 2009-04-03 15:20:01 -0500 (Fri, 03 Apr 2009) | 11 lines
  
  Merged revisions 186458 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186458 | kpfleming | 2009-04-03 15:19:20 -0500 (Fri, 03 Apr 2009) | 5 lines
    
    Fix a bug where DAHDI/Zaptel channels would not properly switch formats when requested
    
    Don't offer AST_FORMAT_SLINEAR on DAHDI/Zaptel channels... while it could provide a slight performance benefit, the translation core in Asterisk has some flaws when a channel driver offers multiple raw formats. this fix is much simpler than fixing the translation core to solve that issue (although that will be done later).
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186463 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 20:20:52 +00:00
Tilghman Lesher
89c6baed8c Merged revisions 186444 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186444 | tilghman | 2009-04-03 14:30:34 -0500 (Fri, 03 Apr 2009) | 14 lines
  
  Merged revisions 186415 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186415 | tilghman | 2009-04-03 14:06:58 -0500 (Fri, 03 Apr 2009) | 7 lines
    
    Distinguish in a sent email between simple sends and forwards.
    (closes issue #11678)
     Reported by: jamessan
     Patches: 
           20090330__bug11678.diff.txt uploaded by tilghman (license 14)
     Tested by: tilghman, lmadsen
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186446 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 19:58:21 +00:00
David Vossel
c248c0cca2 Merged revisions 186379 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r186379 | dvossel | 2009-04-03 11:29:47 -0500 (Fri, 03 Apr 2009) | 4 lines
  
  audio_audiohook_write_list() did not correctly update sample size after ast_translate.
  
  audio_audiohook_write_list() did not take into account that the sample size may change after translation depending on if the original frame is is 8khz or 16khz.  the sample size is now updated after translating to reflect this possibility.  This caused the audio on the receiving end to sound terrible.  Thanks to jcolp and mmichelson for helping me work this out.

  (issue AST-197)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186380 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 16:36:44 +00:00
Joshua Colp
01dc8d8ea9 Merged revisions 186321 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186321 | file | 2009-04-03 12:52:50 -0300 (Fri, 03 Apr 2009) | 12 lines
  
  Merged revisions 186320 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186320 | file | 2009-04-03 12:48:56 -0300 (Fri, 03 Apr 2009) | 5 lines
    
    Fix a problem with the crypto variable definitions not actually being defined properly.
    
    (closes issue #14804)
    Reported by: jvandal
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186322 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 15:53:32 +00:00
Mark Michelson
968ae201df Merged revisions 186286 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r186286 | mmichelson | 2009-04-03 09:32:05 -0500 (Fri, 03 Apr 2009) | 20 lines
  
  Fix the ability to retrieve voicemail messages from IMAP.
  
  A recent change made interactive vm_states no longer get
  added to the list of vm_states and instead get stored in
  thread-local storage.
  
  In trunk and all the 1.6.X branches, the problem is that
  when we search for messages in a voicemail box, we would
  attempt to update the appropriate vm_state struct by directly
  searching in the list of vm_states instead of using the
  get_vm_state_by_imap_user function. This meant we could not
  find the interactive vm_state that we wanted.
  
  (closes issue #14685)
  Reported by: BlargMaN
  Patches:
        14685.patch uploaded by mmichelson (license 60)
  Tested by: BlargMaN, qualleyiv, mmichelson
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186287 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 14:32:37 +00:00
Russell Bryant
e379077e6f Merged revisions 186230 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
r186230 | russell | 2009-04-02 21:03:48 -0500 (Thu, 02 Apr 2009) | 29 lines

Merged revisions 186229 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r186229 | russell | 2009-04-02 20:57:44 -0500 (Thu, 02 Apr 2009) | 21 lines

Fix a memory leak in cdr_radius.

I came across this while doing some testing of my ast_channel_ao2 branch.
After running a test overnight that generated over 5 million calls, Asterisk
had taken up about 1 GB of my system memory.  So, I re-ran the test with
MALLOC_DEBUG turned on.  However, it showed no leaks in Asterisk during the
test, even though Asterisk was still consuming it somehow.

Instead, I turned to valgrind, which when run with --leak-check=full, told
me exactly where the leak came from, which was from allocations inside the
radiusclient-ng library.  This explains why MALLOC_DEBUG did not report it.

After a bit of analysis, I found that we were leaking a little bit of memory
every time a CDR record was passed to cdr_radius.

I don't actually have a radius server set up to receive CDR records.  However,
I always have my development systems compile and install all modules.  In
addition to making sure there are not build errors across modules, always
loading modules helps find bugs like this, too, so it is strongly recommend for
all developers.

........

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186231 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 02:05:29 +00:00
Mark Michelson
00e9f4ca9a Merged revisions 186175 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186175 | mmichelson | 2009-04-02 16:56:21 -0500 (Thu, 02 Apr 2009) | 11 lines
  
  Merged revisions 186174 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186174 | mmichelson | 2009-04-02 16:55:34 -0500 (Thu, 02 Apr 2009) | 5 lines
    
    Fix instructions in one-step parking comment to make more sense.
    
    Changed a capital K to a lowercase k.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186176 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 21:58:37 +00:00
Kevin P. Fleming
04670fdac8 Merged revisions 186101 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186101 | kpfleming | 2009-04-02 12:26:07 -0500 (Thu, 02 Apr 2009) | 9 lines
  
  Merged revisions 186081 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r186081 | kpfleming | 2009-04-02 12:21:29 -0500 (Thu, 02 Apr 2009) | 3 lines
    
    ensure that the buffer passed to DAHDI_SET_BUFINFO is fully initialized
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186105 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 17:27:11 +00:00
Tilghman Lesher
5225fc08dc Merged revisions 186060 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r186060 | tilghman | 2009-04-02 12:10:28 -0500 (Thu, 02 Apr 2009) | 16 lines
  
  Merged revisions 186059 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ................
    r186059 | tilghman | 2009-04-02 12:09:13 -0500 (Thu, 02 Apr 2009) | 9 lines
    
    Merged revisions 186056 via svnmerge from 
    https://origsvn.digium.com/svn/asterisk/branches/1.2
    
    ........
      r186056 | tilghman | 2009-04-02 12:02:18 -0500 (Thu, 02 Apr 2009) | 2 lines
      
      Fix for AST-2009-003
    ........
  ................
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@186061 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 17:12:40 +00:00
Kevin P. Fleming
ee5f6af8c6 Merged revisions 164602 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r164602 | russell | 2008-12-16 08:17:45 -0600 (Tue, 16 Dec 2008) | 7 lines
  
  Fix usage of the DAHDI_VMWI ioctl.
  
  (closes issue #14090)
  Reported by: alecdavis
  Patches:
        chan_dahdi.VMWI_ioctl.diff.txt uploaded by alecdavis (license 585)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185960 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 13:57:07 +00:00
Kevin P. Fleming
7f8d648dc8 this fix should not be blocked from this branch... will merge in a moment
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185959 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 13:56:30 +00:00
Kevin P. Fleming
901b525432 Merged revisions 185953 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185953 | kpfleming | 2009-04-02 08:51:44 -0500 (Thu, 02 Apr 2009) | 11 lines
  
  Merged revisions 185952 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185952 | kpfleming | 2009-04-02 08:43:43 -0500 (Thu, 02 Apr 2009) | 5 lines
    
    the DAHDI_GETCONF, DAHDI_SETCONF and DAHDI_GET_PARAMS ioctls were recently corrected to show that they do, in fact, read data from userspace as part of their work. due to this fix, valgrind now reports a number of cases where chan_dahdi passed an uninitialized (or partially) buffer to these ioctls, which could lead to unexpected behavior.
    
    this patch corrects chan_dahdi to ensure that buffers passed to these ioctls are always fully initialized.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185954 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-02 13:52:35 +00:00
David Vossel
5e9150506c Merged revisions 185846 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185846 | dvossel | 2009-04-01 14:03:32 -0500 (Wed, 01 Apr 2009) | 16 lines
  
  Merged revisions 185845 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185845 | dvossel | 2009-04-01 14:02:00 -0500 (Wed, 01 Apr 2009) | 10 lines
    
    Fixes issue with dropped calles due to re-Invite glare and re-Invites never executing after a 491
    
    Acknowledgement for 491 responses were never being processed because it didn't match our pending invite's seqno.  Since the ACK was never processed, the 491 frame would continue to be retransmitted until eventually the call was dropped due to max retries.  Now during a pending invite, if we receive another invite, we send an 491 and hold on to that glare invite's seqno in the "glareinvite" variable for that sip_pvt struct.  When ACK's are received, we first check to see if it is in response to our pending invite, if not we check to see if it is in response to a glare invite.  In this case, it is in response to the glare invite and must be dealt with or the call is dropped.  I've changed the wait time for resending the re-Invite after receving a 491 response to comply with RFC 3261.  Before this patch the scheduled re-Invite would only change a flag indicating that the re-Invite should be sent out, now it actually sends it out as well. 
    
    (closes issue #12013)
    Reported by: alx
    
    Review: http://reviewboard.digium.com/r/213/
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185847 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-01 19:05:27 +00:00
Mark Michelson
d4f9141500 Blocked revisions 185777 via svnmerge
........
  r185777 | mmichelson | 2009-04-01 08:59:34 -0500 (Wed, 01 Apr 2009) | 5 lines
  
  Address Russell's comments regarding rev 185704.
  
  Use ast_debug and ast_softhangup_nolock.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185778 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-01 14:00:21 +00:00
Russell Bryant
e0b7350f8a Merged revisions 185772 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
r185772 | russell | 2009-04-01 08:48:26 -0500 (Wed, 01 Apr 2009) | 14 lines

Merged revisions 185771 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r185771 | russell | 2009-04-01 08:47:30 -0500 (Wed, 01 Apr 2009) | 6 lines

Fix a case where DTMF could bypass audiohooks.

This change fixes a situation where an audiohook that wants DTMF would not
actually get it.  This is in the code path where we end DTMF digit length
emulation while handling a NULL frame.

........

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185773 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-01 13:49:26 +00:00
Mark Michelson
96da477709 Blocked revisions 185704 via svnmerge
........
  r185704 | mmichelson | 2009-03-31 19:39:01 -0500 (Tue, 31 Mar 2009) | 8 lines
  
  Allow the AMI Hangup command to accept a Cause header.
  
  (closes issue #14695)
  Reported by: mneuhauser
  Patches:
        cause-for-hangup-manager-action.patch uploaded by mneuhauser (license 425)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185707 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-01 00:41:24 +00:00
Kevin P. Fleming
562fb46389 Merged revisions 185664 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r185664 | kpfleming | 2009-03-31 17:35:07 -0500 (Tue, 31 Mar 2009) | 1 line
  
  ignore copied (generated) file
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185665 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 22:37:38 +00:00
Mark Michelson
a64e0f70ea Merged revisions 185600 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185600 | mmichelson | 2009-03-31 17:02:48 -0500 (Tue, 31 Mar 2009) | 12 lines
  
  Merged revisions 185599 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185599 | mmichelson | 2009-03-31 17:00:01 -0500 (Tue, 31 Mar 2009) | 6 lines
    
    Fix crash that would occur if an empty member was specified in queues.conf.
    
    (closes issue #14796)
    Reported by: pida
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185601 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 22:03:55 +00:00
Kevin P. Fleming
72f3dfafbc Blocked revisions 185581 via svnmerge
........
  r185581 | kpfleming | 2009-03-31 16:29:50 -0500 (Tue, 31 Mar 2009) | 19 lines
  
  Optimizations to the stringfields API
  
  This patch provides a number of optimizations to the stringfields API, focused around saving (not wasting) memory whenever possible. Thanks to Mark Michelson for inspiring this work and coming up with the first two optimizations that are represented here:
  
  Changes:
  
  - Cleanup of some code, fix incorrect doxygen comments
  
  - When a field is emptied or replaced with a new allocation, decrease the amount of 'active' space in the pool it was held in; if that pool reaches zero active space, and is not the current pool, then free it as it is no longer in use
  
  - When allocating a pool, try to allocate a size that will fit in a 'standard' malloc() allocation without wasting space
  
  - When allocating space for a field, store the amount of space in the two bytes immediately preceding the field; this eliminates the need to call strlen() on the field when overwriting it, and more importantly it 'remembers' the amount of space the field has available, even if a shorter string has been stored in it since it was allocated
  
  - Don't automatically double the size of each successive pool allocated; it's wasteful
  
  http://reviewboard.digium.com/r/165/
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185591 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 21:31:58 +00:00
Mark Michelson
411feb27b2 Blocked revisions 185532 via svnmerge
................
  r185532 | mmichelson | 2009-03-31 15:56:46 -0500 (Tue, 31 Mar 2009) | 8 lines
  
  Blocked revisions 185531 via svnmerge
  
  ........
    r185531 | mmichelson | 2009-03-31 15:55:47 -0500 (Tue, 31 Mar 2009) | 3 lines
    
    Use AST_SCHED_DEL_SPINLOCK instead of manually using the logic.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185533 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 20:59:06 +00:00
Mark Michelson
a89b373c43 Merged revisions 185469 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185469 | mmichelson | 2009-03-31 14:46:18 -0500 (Tue, 31 Mar 2009) | 14 lines
  
  Merged revisions 185468 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185468 | mmichelson | 2009-03-31 14:45:30 -0500 (Tue, 31 Mar 2009) | 8 lines
    
    Fix Russian voicemail intro to say the word "messages" properly.
    
    (closes issue #14736)
    Reported by: chappell
    Patches:
          voicemail_no_messages.diff uploaded by chappell (license 8)
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185470 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 19:46:52 +00:00
Mark Michelson
eabc30725a Blocked revisions 185299 via svnmerge
................
  r185299 | mmichelson | 2009-03-31 10:34:29 -0500 (Tue, 31 Mar 2009) | 15 lines
  
  Blocked revisions 185298 via svnmerge
  
  ........
    r185298 | mmichelson | 2009-03-31 10:34:05 -0500 (Tue, 31 Mar 2009) | 10 lines
    
    Fix some state_interface stuff that was in trunk but not in the backport to 1.4.
    
    Issue #14359 was fixed between the time that I posted the review of the backport
    of the state interface change for 1.4. This merges the changes from that issue
    back into 1.4.
    
    (closes issue #14359)
    Reported by: francesco_r
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185466 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 19:39:52 +00:00
David Brooks
bf746fcb47 Merged revisions 185363 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185363 | dbrooks | 2009-03-31 11:46:57 -0500 (Tue, 31 Mar 2009) | 44 lines
  
  Merged revisions 185362 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185362 | dbrooks | 2009-03-31 11:37:12 -0500 (Tue, 31 Mar 2009) | 35 lines
    
    Fix incorrect parsing in chan_gtalk when xmpp contains extra whitespaces
    
    To drill into the xmpp to find the capabilities between channels, chan_gtalk 
    calls iks_child() and iks_next(). iks_child() and iks_next() are functions in 
    the iksemel xml parsing library that traverse xml nodes. The bug here is that 
    both iks_child() and iks_next() will return the next iks_struct node 
    *regardless* of type. chan_gtalk expects the next node to be of type IKS_TAG, 
    which in most cases, it is, but in this case (a call being made from the 
    Empathy IM client), there exists iks_struct nodes which are not IKS_TAG data 
    (they are extraneous whitespaces), and chan_gtalk doesn't handle that case, 
    so capabilities don't match, and a call cannot be made.
    
    iks_first_tag() and iks_next_tag(), on the other hand, will not return the 
    very next iks_struct, but will check to see if the next iks_struct is of 
    type IKS_TAG. If it isn't, it will be skipped, and the next struct of type 
    IKS_TAG it finds will be returned. This assures that chan_gtalk will find 
    the iks_struct it is looking for.
    
    This fix simply changes all calls to iks_child() and iks_next() to become 
    calls to iks_first_tag() and iks_next_tag(), which resolves the capability 
    matching.
    
    The following is a payload listing from Empathy, which, due to the extraneous 
    whitespace, will not be parsed correctly by iksemel:
    
    <iq from='dbrooksjab@235-22-24-10/Telepathy' to='astjab@235-22-24-10/asterisk' type='set' id='542757715704'> <session xmlns='http://www.google.com/session' initiator='dbrooksjab@235-22-24-10/Telepathy' type='initiate' id='1837267342'> <description xmlns='http://www.google.com/session/phone'> <payload-type clockrate='16000' name='speex' id='96'/>
     <payload-type clockrate='8000' name='PCMA' id='8'/>
     <payload-type clockrate='8000' name='PCMU' id='0'/>
     <payload-type clockrate='90000' name='MPA' id='97'/>
     <payload-type clockrate='16000' name='SIREN' id='98'/>
     <payload-type clockrate='8000' name='telephone-event' id='99'/>
    </description>
    </session>
    </iq>
  
  Review: http://reviewboard.digium.com/r/181/
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185426 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 17:36:07 +00:00
Russell Bryant
cd84ad1fc0 Merged revisions 185261 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
r185261 | russell | 2009-03-31 09:53:45 -0500 (Tue, 31 Mar 2009) | 5 lines

Don't free() an astobj2 object.

(closes issue #14672)
Reported by: makoto

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185262 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 14:56:27 +00:00
Joshua Colp
d1709254d4 Merged revisions 185197 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185197 | file | 2009-03-31 11:07:36 -0300 (Tue, 31 Mar 2009) | 15 lines
  
  Merged revisions 185196 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185196 | file | 2009-03-31 11:06:39 -0300 (Tue, 31 Mar 2009) | 8 lines
    
    Fix crash when moving audiohooks between channels.
    
    Handle the scenario where we are called to move audiohooks between channels
    and the source channel does not actually have any on it.
    
    (closes issue #14734)
    Reported by: corruptor
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185198 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 14:08:42 +00:00
Richard Mudgett
ae65af4244 Merged revisions 185123 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185123 | rmudgett | 2009-03-30 15:42:14 -0500 (Mon, 30 Mar 2009) | 9 lines
  
  Merged revisions 185121 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185121 | rmudgett | 2009-03-30 15:40:11 -0500 (Mon, 30 Mar 2009) | 1 line
    
    Update the channel allocation method documentation.
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185125 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-30 20:48:08 +00:00
Richard Mudgett
29aa5c71a5 Merged revisions 185122 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185122 | rmudgett | 2009-03-30 15:41:24 -0500 (Mon, 30 Mar 2009) | 26 lines
  
  Merged revisions 185120 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185120 | rmudgett | 2009-03-30 15:38:11 -0500 (Mon, 30 Mar 2009) | 19 lines
    
    Make chan_misdn BRI TE side normally defer channel selection to the NT side.
    
    Channel allocation collisions are not handled by chan_misdn very well.
    This patch simply avoids the problem for BRI only.
    
    For PRI, allocation collisions are still possible but less likely since
    there are simply more channels available and each end could use a different
    allocation strategy.
    
    misdn.conf options available:
    te_choose_channel - Use to force the TE side to allocate channels.
    method - Specify the channel allocation strategy.
    
    (closes issue #13488)
    Reported by: Christian_Pinedo
    Patches:
          isdn_lib.patch.txt uploaded by crich
    Tested by: crich, siepkes, festr
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@185124 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-30 20:46:24 +00:00