[asterisk-commits] file: branch file/bridging r115573 - in /team/file/bridging: ./ apps/ build_t...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu May 8 18:10:30 CDT 2008
Author: file
Date: Thu May 8 18:10:27 2008
New Revision: 115573
URL: http://svn.digium.com/view/asterisk?view=rev&rev=115573
Log:
Merged revisions 115258,115268,115270,115272,115274,115277,115280,115283,115286,115288,115290,115301-115302,115305,115309,115313,115315,115321,115324,115328-115329,115334,115337,115342,115344,115416,115419,115423,115473,115507,115509,115513,115515,115518-115519,115521,115523,115525,115535,115537,115546,115548,115552,115555,115558,115562,115566,115569 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r115258 | bbryant | 2008-05-02 17:26:00 -0300 (Fri, 02 May 2008) | 9 lines
Blocked revisions 115257 via svnmerge
........
r115257 | bbryant | 2008-05-02 15:25:42 -0500 (Fri, 02 May 2008) | 2 lines
Add new "pri show version" command to show the libpri version for support reasons.
........
................
r115268 | dhubbard | 2008-05-03 00:40:32 -0300 (Sat, 03 May 2008) | 11 lines
A taskprocessor is an object that has a name, a task queue, and an event processing thread. Modules reference a taskprocessor, push tasks into the taskprocessor as needed, and unreference the taskprocessor when the taskprocessor is no longer needed.
A task wraps a callback function pointer and a data pointer and is managed internal to the taskprocessor subsystem. The callback function is responsible for releasing task data.
Taskprocessor API
* ast_taskprocessor_get(..) - returns a reference to a taskprocessor
* ast_taskprocessor_unreference(..) - releases reference to a taskprocessor
* ast_taskprocessor_push(..) - push a task into a taskprocessor queue
Check doxygen for more details
................
r115270 | dhubbard | 2008-05-03 00:57:42 -0300 (Sat, 03 May 2008) | 1 line
app_queue uses a taskprocessor for device state changes
................
r115272 | dhubbard | 2008-05-03 01:12:54 -0300 (Sat, 03 May 2008) | 1 line
pbx uses a taskprocessor for device state changes
................
r115274 | dhubbard | 2008-05-03 01:23:18 -0300 (Sat, 03 May 2008) | 1 line
app_voicemail uses a taskprocessor for mwi notification subscriptions
................
r115277 | file | 2008-05-03 22:45:21 -0300 (Sat, 03 May 2008) | 10 lines
Merged revisions 115276 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115276 | file | 2008-05-03 22:43:26 -0300 (Sat, 03 May 2008) | 2 lines
Treat warnings as errors when checking if a GCC attribute exists. We have to do this as GCC will just ignore the attribute and pop up a warning, it won't actually fail to compile.
........
................
r115280 | file | 2008-05-03 22:52:00 -0300 (Sat, 03 May 2008) | 10 lines
Merged revisions 115279 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115279 | file | 2008-05-03 22:50:59 -0300 (Sat, 03 May 2008) | 2 lines
For my next trick I will make these work with what our autoconf header file gives us.
........
................
r115283 | file | 2008-05-03 23:11:01 -0300 (Sat, 03 May 2008) | 10 lines
Merged revisions 115282 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115282 | file | 2008-05-03 23:09:44 -0300 (Sat, 03 May 2008) | 2 lines
Expand the test function for GCC attributes so that more complex attributes are properly recognized.
........
................
r115286 | tilghman | 2008-05-05 00:25:35 -0300 (Mon, 05 May 2008) | 15 lines
Merged revisions 115285 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115285 | tilghman | 2008-05-04 22:22:25 -0500 (Sun, 04 May 2008) | 7 lines
When starting Asterisk, bug out if Asterisk is already running.
(closes issue #12525)
Reported by: explidous
Patches:
20080428__bug12525.diff.txt uploaded by Corydon76 (license 14)
Tested by: mvanbaak
........
................
r115288 | kpfleming | 2008-05-05 07:55:09 -0300 (Mon, 05 May 2008) | 2 lines
clarify wording
................
r115290 | file | 2008-05-05 10:52:44 -0300 (Mon, 05 May 2008) | 6 lines
Document the 'B' option of app_chanspy.
(closes issue #12582)
Reported by: IgorG
Patches:
app_chanspy_B_option.diff uploaded by IgorG (license 20)
................
r115301 | tilghman | 2008-05-05 16:33:14 -0300 (Mon, 05 May 2008) | 3 lines
Optionally display the value of several variables within the Status command.
(Closes issue AST-34)
................
r115302 | tilghman | 2008-05-05 16:42:36 -0300 (Mon, 05 May 2008) | 2 lines
Note change for ExecIf syntax (caught by jmls on IRC)
................
r115305 | russell | 2008-05-05 16:50:24 -0300 (Mon, 05 May 2008) | 13 lines
Merged revisions 115304 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115304 | russell | 2008-05-05 14:49:25 -0500 (Mon, 05 May 2008) | 5 lines
Avoid putting opaque="" in Digest authentication. This patch came from switchvox.
It fixes authentication with Primus in Canada, and has been in use for a very long
time without causing problems with any other providers.
(closes issue AST-36)
........
................
r115309 | tilghman | 2008-05-05 16:57:28 -0300 (Mon, 05 May 2008) | 10 lines
Merged revisions 115308 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115308 | tilghman | 2008-05-05 14:55:55 -0500 (Mon, 05 May 2008) | 2 lines
Err, the documentation on the return value of ast_odbc_backslash_is_escape is exactly backwards.
........
................
r115313 | tilghman | 2008-05-05 17:22:08 -0300 (Mon, 05 May 2008) | 10 lines
Merged revisions 115312 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115312 | tilghman | 2008-05-05 15:17:55 -0500 (Mon, 05 May 2008) | 2 lines
Reverse order, such that user configs override default selections
........
................
r115315 | russell | 2008-05-05 17:28:17 -0300 (Mon, 05 May 2008) | 2 lines
Remove my rant, since I have now replaced the rant with code.
................
r115321 | mmichelson | 2008-05-05 18:43:21 -0300 (Mon, 05 May 2008) | 21 lines
Merged revisions 115320 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115320 | mmichelson | 2008-05-05 16:41:34 -0500 (Mon, 05 May 2008) | 13 lines
Don't consider a caller "handled" until the caller is bridged with
a queue member. There was too much of an opportunity for the member
to hang up (either during a delay, announcement, or overly long
agi) between the time that he answered the phone and the time when
he actually was bridged with the caller. The consequence of this
was that if the member hung up in that interval, then proper
abandonment details would not be noted in the queue log if the caller
were to hang up at any point after the member hangup.
(closes issue #12561)
Reported by: ablackthorn
........
................
r115324 | russell | 2008-05-05 19:01:56 -0300 (Mon, 05 May 2008) | 2 lines
Simplify code by using a taskprocessor for dispatching events in the Asterisk core.
................
r115328 | file | 2008-05-05 19:13:57 -0300 (Mon, 05 May 2008) | 10 lines
Merged revisions 115327 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115327 | file | 2008-05-05 19:10:05 -0300 (Mon, 05 May 2008) | 2 lines
Make sure that either the main speex library contains preprocess functions or that speexdsp does. If both fail then speex stuff can not be built.
........
................
r115329 | mmichelson | 2008-05-05 19:14:06 -0300 (Mon, 05 May 2008) | 15 lines
#execing the same file multiple times led to warning messages saying that the same file was
being #included twice. This was due to the fact that #exec created a temporary file which
was then #included. The name of the temporary file was the name of the #exec'd file, with
the Unix timestamp and thread ID concatenated. The issue was that if multiple #exec statements
of the same file were reached in the same second, then the result was that the temporary files
would have duplicate names. To resolve this, the temporary file now has microsecond resolution
for the timestamp portion.
(closes issue #12574)
Reported by: jmls
Patches:
12574.patch uploaded by putnopvut (license 60)
Tested by: jmls, putnopvut
................
r115334 | tilghman | 2008-05-05 20:00:31 -0300 (Mon, 05 May 2008) | 15 lines
Merged revisions 115333 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115333 | tilghman | 2008-05-05 17:50:31 -0500 (Mon, 05 May 2008) | 7 lines
Separate verbose output from CLI output, by using a preamble.
(closes issue #12402)
Reported by: Corydon76
Patches:
20080410__no_verbose_in_rx_output.diff.txt uploaded by Corydon76 (license 14)
20080501__no_verbose_in_rx_output__1.4.diff.txt uploaded by Corydon76 (license 14)
........
................
r115337 | tilghman | 2008-05-05 20:38:15 -0300 (Mon, 05 May 2008) | 2 lines
Merge refcounting of res_odbc
................
r115342 | file | 2008-05-06 10:55:44 -0300 (Tue, 06 May 2008) | 10 lines
Merged revisions 115341 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115341 | file | 2008-05-06 10:54:15 -0300 (Tue, 06 May 2008) | 2 lines
Add in missing argument.
........
................
r115344 | russell | 2008-05-06 12:14:55 -0300 (Tue, 06 May 2008) | 2 lines
Change some NOTICE log messages to debug.
................
r115416 | tilghman | 2008-05-06 16:32:29 -0300 (Tue, 06 May 2008) | 10 lines
Merged revisions 115415 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115415 | tilghman | 2008-05-06 14:31:39 -0500 (Tue, 06 May 2008) | 2 lines
Don't print the terminating NUL. (Closes issue #12589)
........
................
r115419 | qwell | 2008-05-06 16:38:44 -0300 (Tue, 06 May 2008) | 15 lines
Merged revisions 115418 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115418 | qwell | 2008-05-06 14:34:58 -0500 (Tue, 06 May 2008) | 7 lines
Switch to using ast_random() rather than just rand().
This does not fix the bug reported, but I believe it is correct.
(from issue #12446)
Patches:
bug_12446.diff uploaded by snuffy (license 35)
........
................
r115423 | qwell | 2008-05-06 16:55:45 -0300 (Tue, 06 May 2008) | 23 lines
Merged revisions 115422 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
................
r115422 | qwell | 2008-05-06 14:55:29 -0500 (Tue, 06 May 2008) | 15 lines
Merged revisions 115421 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r115421 | qwell | 2008-05-06 14:54:57 -0500 (Tue, 06 May 2008) | 7 lines
read requires an argument on some non-bash shells
(closes issue #12593)
Reported by: bkruse
Patches:
getilbc.sh_12593_v1.diff uploaded by bkruse (license 132)
........
................
................
r115473 | mmichelson | 2008-05-06 17:15:02 -0300 (Tue, 06 May 2008) | 3 lines
Get refcounter to build with LOW_MEMORY defined
................
r115507 | file | 2008-05-07 10:41:25 -0300 (Wed, 07 May 2008) | 4 lines
Remove redundant header getting.
(closes issue #12597)
Reported by: hooi
................
r115509 | tilghman | 2008-05-07 10:49:15 -0300 (Wed, 07 May 2008) | 6 lines
Update typos in description fields
(closes issue #12598)
Reported by: suretec
Patches:
asterisk_schema_changes.patch uploaded by suretec (license 70)
................
r115513 | russell | 2008-05-07 14:28:19 -0300 (Wed, 07 May 2008) | 19 lines
Merged revisions 115512 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
................
r115512 | russell | 2008-05-07 11:24:09 -0500 (Wed, 07 May 2008) | 11 lines
Merged revisions 115511 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r115511 | russell | 2008-05-07 11:22:49 -0500 (Wed, 07 May 2008) | 3 lines
Remove remnants of dlinkedlists. I didn't actually use them in the final version
of my IAX2 improvements.
........
................
................
r115515 | russell | 2008-05-07 14:38:36 -0300 (Wed, 07 May 2008) | 2 lines
re-add dlinkedlists.h to trunk, oops!
................
r115518 | russell | 2008-05-07 15:17:43 -0300 (Wed, 07 May 2008) | 12 lines
Blocked revisions 115517 via svnmerge
........
r115517 | russell | 2008-05-07 13:17:19 -0500 (Wed, 07 May 2008) | 5 lines
Track peer references when stored in the sip_pvt struct as the peer related to
a qualify ping or a subscription. This fixes some realtime related crashes.
(closes issue #12588)
(closes issue #12555)
........
................
r115519 | russell | 2008-05-07 15:24:51 -0300 (Wed, 07 May 2008) | 2 lines
Let chan_h323 build in dev mode
................
r115521 | russell | 2008-05-07 15:30:12 -0300 (Wed, 07 May 2008) | 7 lines
Use the default that the log output claims will be used for the basedn
(closes issue #12599)
Reported by: suretec
Patches:
12599.patch uploaded by juggie (license 24)
................
r115523 | russell | 2008-05-07 15:33:50 -0300 (Wed, 07 May 2008) | 6 lines
Only save a password if a username exists.
(closes issue #12600)
Reported By: suretec
Patch by me
................
r115525 | tilghman | 2008-05-07 15:40:21 -0300 (Wed, 07 May 2008) | 2 lines
Don't free the object on destroy, as astobj2 takes care of that for you
................
r115535 | tilghman | 2008-05-07 17:22:09 -0300 (Wed, 07 May 2008) | 2 lines
Advance to next sounds release
................
r115537 | russell | 2008-05-07 18:11:33 -0300 (Wed, 07 May 2008) | 10 lines
Fix up a problem that was introduced into the scheduler when it was converted
to use doubly linked lists. The schedule() function had an optimization that
had it try to guess which direction would be better for the traversal to insert
the task into the scheduler queue. However, if the code chose the path where
it traversed the queue in reverse, and the result was that the task should be
at the head of the queue, then the code would actually put it at the tail,
instead.
(Problem found by bbryant, debugged and fixed by bbryant and me)
................
r115546 | russell | 2008-05-08 11:41:12 -0300 (Thu, 08 May 2008) | 12 lines
Merged revisions 115545 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115545 | russell | 2008-05-08 09:40:53 -0500 (Thu, 08 May 2008) | 4 lines
Use the same method for executing Asterisk as the rest of the script.
(closes issue #12611)
Reported by: b_plessis
........
................
r115548 | mattf | 2008-05-08 12:04:45 -0300 (Thu, 08 May 2008) | 1 line
Remove unused code as well as demote an error message to a debug message
................
r115552 | russell | 2008-05-08 12:26:49 -0300 (Thu, 08 May 2008) | 12 lines
Merged revisions 115551 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115551 | russell | 2008-05-08 10:24:54 -0500 (Thu, 08 May 2008) | 4 lines
Don't use a channel before checking for channel allocation failure.
(closes issue #12609)
Reported by: edantie
........
................
r115555 | russell | 2008-05-08 12:32:48 -0300 (Thu, 08 May 2008) | 11 lines
Merged revisions 115554 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115554 | russell | 2008-05-08 10:32:08 -0500 (Thu, 08 May 2008) | 3 lines
Don't exit the script if Asterisk is not running.
(closes issue #12611)
........
................
r115558 | russell | 2008-05-08 12:38:27 -0300 (Thu, 08 May 2008) | 11 lines
Merged revisions 115557 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115557 | russell | 2008-05-08 10:37:49 -0500 (Thu, 08 May 2008) | 3 lines
remove postgres_cdr.sql, as the CDR schema is in realtime_pgsql.sql, as well
(closes issue #9676)
........
................
r115562 | russell | 2008-05-08 13:14:08 -0300 (Thu, 08 May 2008) | 11 lines
Merged revisions 115561 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115561 | russell | 2008-05-08 11:11:33 -0500 (Thu, 08 May 2008) | 3 lines
Don't give up on attempting an outbound registration if we receive a 408 Timeout.
(closes issue #12323)
........
................
r115566 | russell | 2008-05-08 16:17:04 -0300 (Thu, 08 May 2008) | 41 lines
Merged revisions 115565 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
................
r115565 | russell | 2008-05-08 14:15:25 -0500 (Thu, 08 May 2008) | 33 lines
Merged revisions 115564 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r115564 | russell | 2008-05-08 14:14:04 -0500 (Thu, 08 May 2008) | 25 lines
Fix a race condition that bbryant just found while doing some IAX2 testing.
He was running Asterisk trunk running IAX2 calls through a few Asterisk boxes,
however, the audio was extremely choppy. We looked at a packet trace and saw
a storm of INVAL and VNAK frames being sent from one box to another.
It turned out that what had happened was that one box tried to send a CONTROL
frame before the 3 way handshake had completed. So, that frame did not include
the destination call number, because it didn't have it yet. Part of our recent
work for security issues included an additional check to ensure that frames that
are supposed to include the destination call number have the correct one. This
caused the frame to be rejected with an INVAL. The frame would get retransmitted
for forever, rejected every time ...
This race condition exists in all versions that got the security changes,
in theory. However, it is really only likely that this would cause a problem in
Asterisk trunk. There was a control frame being sent (SRCUPDATE) at the _very_
beginning of the call, which does not exist in 1.2 or 1.4. However, I am fixing
all versions that could potentially be affected by the introduced race condition.
These changes are what bbryant and I came up with to fix the issue. Instead of
simply dropping control frames that get sent before the handshake is complete,
the code attempts to wait a little while, since in most cases, the handshake
will complete very quickly. If it doesn't complete after yielding for a little
while, then the frame gets dropped.
........
................
................
r115569 | russell | 2008-05-08 16:20:35 -0300 (Thu, 08 May 2008) | 10 lines
Merged revisions 115568 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r115568 | russell | 2008-05-08 14:19:50 -0500 (Thu, 08 May 2008) | 2 lines
Remove debug output.
........
................
Added:
team/file/bridging/include/asterisk/taskprocessor.h
- copied unchanged from r115569, trunk/include/asterisk/taskprocessor.h
team/file/bridging/main/taskprocessor.c
- copied unchanged from r115569, trunk/main/taskprocessor.c
Removed:
team/file/bridging/contrib/scripts/postgres_cdr.sql
Modified:
team/file/bridging/ (props changed)
team/file/bridging/CHANGES
team/file/bridging/Makefile
team/file/bridging/UPGRADE.txt
team/file/bridging/acinclude.m4
team/file/bridging/apps/app_chanspy.c
team/file/bridging/apps/app_queue.c
team/file/bridging/apps/app_voicemail.c
team/file/bridging/build_tools/menuselect-deps.in
team/file/bridging/channels/chan_h323.c
team/file/bridging/channels/chan_iax2.c
team/file/bridging/channels/chan_sip.c
team/file/bridging/channels/chan_zap.c
team/file/bridging/codecs/codec_speex.c
team/file/bridging/configure
team/file/bridging/configure.ac
team/file/bridging/contrib/init.d/rc.debian.asterisk
team/file/bridging/contrib/init.d/rc.gentoo.asterisk
team/file/bridging/contrib/init.d/rc.mandrake.asterisk
team/file/bridging/contrib/init.d/rc.redhat.asterisk
team/file/bridging/contrib/init.d/rc.slackware.asterisk
team/file/bridging/contrib/init.d/rc.suse.asterisk
team/file/bridging/contrib/scripts/asterisk.ldap-schema
team/file/bridging/contrib/scripts/asterisk.ldif
team/file/bridging/contrib/scripts/get_ilbc_source.sh
team/file/bridging/contrib/scripts/safe_asterisk
team/file/bridging/funcs/func_speex.c
team/file/bridging/include/asterisk/_private.h
team/file/bridging/include/asterisk/autoconfig.h.in
team/file/bridging/include/asterisk/compiler.h
team/file/bridging/include/asterisk/dlinkedlists.h (props changed)
team/file/bridging/include/asterisk/res_odbc.h
team/file/bridging/main/Makefile
team/file/bridging/main/asterisk.c
team/file/bridging/main/config.c
team/file/bridging/main/event.c
team/file/bridging/main/logger.c
team/file/bridging/main/manager.c
team/file/bridging/main/pbx.c
team/file/bridging/main/sched.c
team/file/bridging/res/res_config_ldap.c
team/file/bridging/res/res_musiconhold.c
team/file/bridging/res/res_odbc.c
team/file/bridging/sounds/Makefile
team/file/bridging/utils/refcounter.c
Propchange: team/file/bridging/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.
Propchange: team/file/bridging/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.
Propchange: team/file/bridging/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu May 8 18:10:27 2008
@@ -1,1 +1,1 @@
-/trunk:1-115204
+/trunk:1-115572
Modified: team/file/bridging/CHANGES
URL: http://svn.digium.com/view/asterisk/team/file/bridging/CHANGES?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/CHANGES (original)
+++ team/file/bridging/CHANGES Thu May 8 18:10:27 2008
@@ -96,6 +96,11 @@
Dialplan function changes
-------------------------
* TIMEOUT() has been modified to be accurate down to the millisecond.
+
+AMI - The manager (TCP/TLS/HTTP)
+--------------------------------
+ * The Status command now takes an optional list of variables to display
+ along with channel status.
------------------------------------------------------------------------------
--- Functionality changes from Asterisk 1.4.X to Asterisk 1.6.0 -------------
Modified: team/file/bridging/Makefile
URL: http://svn.digium.com/view/asterisk/team/file/bridging/Makefile?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/Makefile (original)
+++ team/file/bridging/Makefile Thu May 8 18:10:27 2008
@@ -351,7 +351,7 @@
@exit 1
menuselect.makeopts: menuselect/menuselect menuselect-tree makeopts
- menuselect/menuselect --check-deps $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) menuselect.makeopts
+ menuselect/menuselect --check-deps menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS)
$(MOD_SUBDIRS_EMBED_LDSCRIPT):
@echo "EMBED_LDSCRIPTS+="`$(SILENTMAKE) -C $(@:-embed-ldscript=) SUBDIR=$(@:-embed-ldscript=) __embed_ldscript` >> makeopts.embed_rules
@@ -821,16 +821,16 @@
nmenuconfig: nmenuselect
menuselect: menuselect/menuselect menuselect-tree
- - at menuselect/menuselect $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) menuselect.makeopts && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
+ - at menuselect/menuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
cmenuselect: menuselect/cmenuselect menuselect-tree
- - at menuselect/cmenuselect $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) menuselect.makeopts && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
+ - at menuselect/cmenuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
gmenuselect: menuselect/gmenuselect menuselect-tree
- - at menuselect/gmenuselect $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) menuselect.makeopts && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
+ - at menuselect/gmenuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
nmenuselect: menuselect/nmenuselect menuselect-tree
- - at menuselect/nmenuselect $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) menuselect.makeopts && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
+ - at menuselect/nmenuselect menuselect.makeopts $(GLOBAL_MAKEOPTS) $(USER_MAKEOPTS) && (echo "menuselect changes saved!"; rm -f channels/h323/Makefile.ast main/asterisk) || echo "menuselect changes NOT saved!"
# options for make in menuselect/
MAKE_MENUSELECT=CC="$(HOST_CC)" CXX="$(CXX)" LD="" AR="" RANLIB="" CFLAGS="" $(MAKE) -C menuselect CONFIGURE_SILENT="--silent"
@@ -869,4 +869,4 @@
asterisk.pdf:
$(MAKE) -C doc/tex asterisk.pdf
-.PHONY: menuselect main sounds clean dist-clean distclean all prereqs cleantest uninstall _uninstall uninstall-all pdf dont-optimize $(SUBDIRS_INSTALL) $(SUBDIRS_DIST_CLEAN) $(SUBDIRS_CLEAN) $(SUBDIRS_UNINSTALL) $(SUBDIRS) $(MOD_SUBDIRS_EMBED_LDSCRIPT) $(MOD_SUBDIRS_EMBED_LDFLAGS) $(MOD_SUBDIRS_EMBED_LIBS) badshell main/version.c include/asterisk/version.h installdirs
+.PHONY: menuselect menuselect.makeopts main sounds clean dist-clean distclean all prereqs cleantest uninstall _uninstall uninstall-all pdf dont-optimize $(SUBDIRS_INSTALL) $(SUBDIRS_DIST_CLEAN) $(SUBDIRS_CLEAN) $(SUBDIRS_UNINSTALL) $(SUBDIRS) $(MOD_SUBDIRS_EMBED_LDSCRIPT) $(MOD_SUBDIRS_EMBED_LDFLAGS) $(MOD_SUBDIRS_EMBED_LIBS) badshell main/version.c include/asterisk/version.h installdirs
Modified: team/file/bridging/UPGRADE.txt
URL: http://svn.digium.com/view/asterisk/team/file/bridging/UPGRADE.txt?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/UPGRADE.txt (original)
+++ team/file/bridging/UPGRADE.txt Thu May 8 18:10:27 2008
@@ -94,8 +94,8 @@
these functions in any location where you desire to ensure that only one
channel is executing that path at any one time. The Macro() applications
are deprecated for performance reasons. However, since Macro() has been
- around for a long time and so many dialplans depend heavily on it, it will
- not be removed for the sake of backwards compatibility. It is also worth
+ around for a long time and so many dialplans depend heavily on it, for the
+ sake of backwards compatibility it will not be removed . It is also worth
noting that using both Macro() and GoSub() at the same time is _heavily_
discouraged.
* Read() now sets a READSTATUS variable on exit. It does NOT automatically
@@ -110,6 +110,8 @@
instead.
* While app_directory has always relied on having a voicemail.conf or users.conf file
correctly set up, it now is dependent on app_voicemail being compiled as well.
+* The arguments in ExecIf changed a bit, to be more like other applications.
+ The syntax is now ExecIf(<cond>?appiftrue(args):appiffalse(args)).
Dialplan Functions:
Modified: team/file/bridging/acinclude.m4
URL: http://svn.digium.com/view/asterisk/team/file/bridging/acinclude.m4?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/acinclude.m4 (original)
+++ team/file/bridging/acinclude.m4 Thu May 8 18:10:27 2008
@@ -7,13 +7,17 @@
AC_DEFUN([AST_GCC_ATTRIBUTE],
[
AC_MSG_CHECKING(for compiler 'attribute $1' support)
+saved_CFLAGS="$CFLAGS"
+CFLAGS="$CFLAGS -Werror"
AC_COMPILE_IFELSE(
- AC_LANG_PROGRAM([static int __attribute__(($1)) test(void) {}],
+ AC_LANG_PROGRAM([static void __attribute__(($1)) *test(void *muffin, ...) {}],
[]),
AC_MSG_RESULT(yes)
AC_DEFINE_UNQUOTED([HAVE_ATTRIBUTE_$1], 1, [Define to 1 if your GCC C compiler supports the '$1' attribute.]),
AC_MSG_RESULT(no))
-])
+]
+CFLAGS="$saved_CFLAGS"
+)
# Helper function to setup variables for a package.
# $1 -> the package name. Used in configure.ac and also as a prefix
Modified: team/file/bridging/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/team/file/bridging/apps/app_chanspy.c?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/apps/app_chanspy.c (original)
+++ team/file/bridging/apps/app_chanspy.c Thu May 8 18:10:27 2008
@@ -71,6 +71,8 @@
" and a digit sequence.\n"
" Options:\n"
" b - Only spy on channels involved in a bridged call.\n"
+" B - Instead of whispering on a single channel barge in on both\n"
+" channels involved in the call.\n"
" g(grp) - Only spy on channels in which one or more of the groups \n"
" listed in 'grp' matches one or more groups from the\n"
" SPYGROUP variable set on the channel to be spied upon.\n"
Modified: team/file/bridging/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/file/bridging/apps/app_queue.c?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/apps/app_queue.c (original)
+++ team/file/bridging/apps/app_queue.c Thu May 8 18:10:27 2008
@@ -92,6 +92,7 @@
#include "asterisk/astobj2.h"
#include "asterisk/strings.h"
#include "asterisk/global_datastores.h"
+#include "asterisk/taskprocessor.h"
/*!
* \par Please read before modifying this file.
@@ -130,6 +131,8 @@
{ QUEUE_STRATEGY_LINEAR, "linear" },
{ QUEUE_STRATEGY_WRANDOM, "wrandom"},
};
+
+static struct ast_taskprocessor *devicestate_tps;
#define DEFAULT_RETRY 5
#define DEFAULT_TIMEOUT 15
@@ -739,18 +742,20 @@
}
/*! \brief set a member's status based on device state of that member's interface*/
-static void *handle_statechange(struct statechange *sc)
+static int handle_statechange(void *datap)
{
struct member_interface *curint;
char *loc;
char *technology;
+ struct statechange *sc = datap;
technology = ast_strdupa(sc->dev);
loc = strchr(technology, '/');
if (loc) {
*loc++ = '\0';
} else {
- return NULL;
+ ast_free(sc);
+ return 0;
}
AST_LIST_LOCK(&interfaces);
@@ -770,84 +775,14 @@
if (!curint) {
if (option_debug > 2)
ast_log(LOG_DEBUG, "Device '%s/%s' changed to state '%d' (%s) but we don't care because they're not a member of any queue.\n", technology, loc, sc->state, devstate2str(sc->state));
- return NULL;
+ return 0;
}
if (option_debug)
ast_log(LOG_DEBUG, "Device '%s/%s' changed to state '%d' (%s)\n", technology, loc, sc->state, devstate2str(sc->state));
update_status(sc->dev, sc->state);
-
- return NULL;
-}
-
-/*! \brief Data used by the device state thread */
-static struct {
- /*! Set to 1 to stop the thread */
- unsigned int stop:1;
- /*! The device state monitoring thread */
- pthread_t thread;
- /*! Lock for the state change queue */
- ast_mutex_t lock;
- /*! Condition for the state change queue */
- ast_cond_t cond;
- /*! Queue of state changes */
- AST_LIST_HEAD_NOLOCK(, statechange) state_change_q;
-} device_state = {
- .thread = AST_PTHREADT_NULL,
-};
-
-/*! \brief Consumer of the statechange queue */
-static void *device_state_thread(void *data)
-{
- struct statechange *sc = NULL;
-
- while (!device_state.stop) {
- ast_mutex_lock(&device_state.lock);
- if (!(sc = AST_LIST_REMOVE_HEAD(&device_state.state_change_q, entry))) {
- ast_cond_wait(&device_state.cond, &device_state.lock);
- sc = AST_LIST_REMOVE_HEAD(&device_state.state_change_q, entry);
- }
- ast_mutex_unlock(&device_state.lock);
-
- /* Check to see if we were woken up to see the request to stop */
- if (device_state.stop)
- break;
-
- if (!sc)
- continue;
-
- handle_statechange(sc);
-
- ast_free(sc);
- sc = NULL;
- }
-
- if (sc)
- ast_free(sc);
-
- while ((sc = AST_LIST_REMOVE_HEAD(&device_state.state_change_q, entry)))
- ast_free(sc);
-
- return NULL;
-}
-
-/*! \brief Producer of the statechange queue */
-static int statechange_queue(const char *dev, enum ast_device_state state)
-{
- struct statechange *sc;
-
- if (!(sc = ast_calloc(1, sizeof(*sc) + strlen(dev) + 1)))
- return 0;
-
- sc->state = state;
- strcpy(sc->dev, dev);
-
- ast_mutex_lock(&device_state.lock);
- AST_LIST_INSERT_TAIL(&device_state.state_change_q, sc, entry);
- ast_cond_signal(&device_state.cond);
- ast_mutex_unlock(&device_state.lock);
-
+ ast_free(sc);
return 0;
}
@@ -855,6 +790,8 @@
{
enum ast_device_state state;
const char *device;
+ struct statechange *sc;
+ size_t datapsize;
state = ast_event_get_ie_uint(event, AST_EVENT_IE_STATE);
device = ast_event_get_ie_str(event, AST_EVENT_IE_DEVICE);
@@ -863,8 +800,16 @@
ast_log(LOG_ERROR, "Received invalid event that had no device IE\n");
return;
}
-
- statechange_queue(device, state);
+ datapsize = sizeof(*sc) + strlen(device) + 1;
+ if (!(sc = ast_calloc(1, datapsize))) {
+ ast_log(LOG_ERROR, "failed to calloc a state change struct\n");
+ return;
+ }
+ sc->state = state;
+ strcpy(sc->dev, device);
+ if (ast_taskprocessor_push(devicestate_tps, handle_statechange, sc) < 0) {
+ ast_free(sc);
+ }
}
/*! \brief allocate space for new queue member and set fields based on parameters passed */
@@ -3349,7 +3294,6 @@
/* Ah ha! Someone answered within the desired timeframe. Of course after this
we will always return with -1 so that it is hung up properly after the
conversation. */
- qe->handled++;
if (!strcmp(qe->chan->tech->type, "Zap"))
ast_channel_setoption(qe->chan, AST_OPTION_TONE_VERIFY, &nondataquality, sizeof(nondataquality), 0);
if (!strcmp(peer->tech->type, "Zap"))
@@ -3403,7 +3347,6 @@
/* Agent must have hung up */
ast_log(LOG_WARNING, "Agent on %s hungup on the customer.\n", peer->name);
ast_queue_log(queuename, qe->chan->uniqueid, member->membername, "AGENTDUMP", "%s", "");
- record_abandoned(qe);
if (qe->parent->eventwhencalled)
manager_event(EVENT_FLAG_AGENT, "AgentDump",
"Queue: %s\r\n"
@@ -3683,6 +3626,7 @@
} else
ast_log(LOG_WARNING, "Asked to execute an AGI on this channel, but could not find application (agi)!\n");
}
+ qe->handled++;
ast_queue_log(queuename, qe->chan->uniqueid, member->membername, "CONNECT", "%ld|%s|%ld", (long) time(NULL) - qe->start, peer->uniqueid,
(long)(orig - to > 0 ? (orig - to) / 1000 : 0));
if (update_cdr && qe->chan->cdr)
@@ -6249,14 +6193,6 @@
struct ao2_iterator q_iter;
struct call_queue *q = NULL;
- if (device_state.thread != AST_PTHREADT_NULL) {
- device_state.stop = 1;
- ast_mutex_lock(&device_state.lock);
- ast_cond_signal(&device_state.cond);
- ast_mutex_unlock(&device_state.lock);
- pthread_join(device_state.thread, NULL);
- }
-
ast_cli_unregister_multiple(cli_queue, sizeof(cli_queue) / sizeof(struct ast_cli_entry));
res = ast_manager_unregister("QueueStatus");
res |= ast_manager_unregister("Queues");
@@ -6296,7 +6232,7 @@
queue_unref(q);
}
ao2_ref(queues, -1);
-
+ devicestate_tps = ast_taskprocessor_unreference(devicestate_tps);
return res;
}
@@ -6318,10 +6254,6 @@
if (queue_persistent_members)
reload_queue_members();
-
- ast_mutex_init(&device_state.lock);
- ast_cond_init(&device_state.cond, NULL);
- ast_pthread_create(&device_state.thread, NULL, device_state_thread, NULL);
ast_cli_register_multiple(cli_queue, sizeof(cli_queue) / sizeof(struct ast_cli_entry));
res = ast_register_application(app, queue_exec, synopsis, descrip);
@@ -6345,6 +6277,11 @@
res |= ast_custom_function_register(&queuememberlist_function);
res |= ast_custom_function_register(&queuewaitingcount_function);
res |= ast_custom_function_register(&queuememberpenalty_function);
+
+ if (!(devicestate_tps = ast_taskprocessor_get("app_queue", 0))) {
+ ast_log(LOG_WARNING, "devicestate taskprocessor reference failed - devicestate notifications will not occur\n");
+ }
+
if (!(device_state_sub = ast_event_subscribe(AST_EVENT_DEVICE_STATE, device_state_cb, NULL, AST_EVENT_IE_END)))
res = -1;
Modified: team/file/bridging/apps/app_voicemail.c
URL: http://svn.digium.com/view/asterisk/team/file/bridging/apps/app_voicemail.c?view=diff&rev=115573&r1=115572&r2=115573
==============================================================================
--- team/file/bridging/apps/app_voicemail.c (original)
+++ team/file/bridging/apps/app_voicemail.c Thu May 8 18:10:27 2008
@@ -114,6 +114,7 @@
#include "asterisk/stringfields.h"
#include "asterisk/smdi.h"
#include "asterisk/event.h"
+#include "asterisk/taskprocessor.h"
#ifdef ODBC_STORAGE
#include "asterisk/res_odbc.h"
@@ -620,6 +621,14 @@
uint32_t uniqueid;
char mailbox[1];
};
+
+struct mwi_sub_task {
+ const char *mailbox;
+ const char *context;
+ uint32_t uniqueid;
+};
+
+static struct ast_taskprocessor *mwi_subscription_tps;
static AST_RWLIST_HEAD_STATIC(mwi_subs, mwi_sub);
@@ -8716,22 +8725,14 @@
ast_free(mwi_sub);
}
-static void mwi_unsub_event_cb(const struct ast_event *event, void *userdata)
-{
- uint32_t uniqueid;
+static int handle_unsubscribe(void *datap)
+{
struct mwi_sub *mwi_sub;
-
- if (ast_event_get_type(event) != AST_EVENT_UNSUB)
- return;
-
- if (ast_event_get_ie_uint(event, AST_EVENT_IE_EVENTTYPE) != AST_EVENT_MWI)
- return;
-
- uniqueid = ast_event_get_ie_uint(event, AST_EVENT_IE_UNIQUEID);
-
+ uint32_t *uniqueid = datap;
+
AST_RWLIST_WRLOCK(&mwi_subs);
AST_RWLIST_TRAVERSE_SAFE_BEGIN(&mwi_subs, mwi_sub, entry) {
- if (mwi_sub->uniqueid == uniqueid) {
+ if (mwi_sub->uniqueid == *uniqueid) {
AST_LIST_REMOVE_CURRENT(entry);
break;
}
@@ -8741,48 +8742,80 @@
if (mwi_sub)
mwi_sub_destroy(mwi_sub);
-}
-
-static void mwi_sub_event_cb(const struct ast_event *event, void *userdata)
-{
- const char *mailbox;
- const char *context;
- uint32_t uniqueid;
+
+ ast_free(uniqueid);
+ return 0;
+}
+
+static int handle_subscribe(void *datap)
+{
unsigned int len;
struct mwi_sub *mwi_sub;
-
- if (ast_event_get_type(event) != AST_EVENT_SUB)
- return;
-
- if (ast_event_get_ie_uint(event, AST_EVENT_IE_EVENTTYPE) != AST_EVENT_MWI)
- return;
-
- mailbox = ast_event_get_ie_str(event, AST_EVENT_IE_MAILBOX);
- context = ast_event_get_ie_str(event, AST_EVENT_IE_CONTEXT);
- uniqueid = ast_event_get_ie_uint(event, AST_EVENT_IE_UNIQUEID);
+ struct mwi_sub_task *p = datap;
len = sizeof(*mwi_sub);
- if (!ast_strlen_zero(mailbox))
- len += strlen(mailbox);
-
- if (!ast_strlen_zero(context))
- len += strlen(context) + 1; /* Allow for seperator */
+ if (!ast_strlen_zero(p->mailbox))
+ len += strlen(p->mailbox);
+
+ if (!ast_strlen_zero(p->context))
+ len += strlen(p->context) + 1; /* Allow for seperator */
if (!(mwi_sub = ast_calloc(1, len)))
- return;
-
- mwi_sub->uniqueid = uniqueid;
- if (!ast_strlen_zero(mailbox))
- strcpy(mwi_sub->mailbox, mailbox);
-
- if (!ast_strlen_zero(context)) {
+ return -1;
+
+ mwi_sub->uniqueid = p->uniqueid;
+ if (!ast_strlen_zero(p->mailbox))
+ strcpy(mwi_sub->mailbox, p->mailbox);
+
+ if (!ast_strlen_zero(p->context)) {
strcat(mwi_sub->mailbox, "@");
- strcat(mwi_sub->mailbox, context);
+ strcat(mwi_sub->mailbox, p->context);
}
AST_RWLIST_WRLOCK(&mwi_subs);
AST_RWLIST_INSERT_TAIL(&mwi_subs, mwi_sub, entry);
AST_RWLIST_UNLOCK(&mwi_subs);
+ ast_free(p);
+ return 0;
+}
+
+static void mwi_unsub_event_cb(const struct ast_event *event, void *userdata)
+{
[... 2175 lines stripped ...]
More information about the asterisk-commits
mailing list