[asterisk-commits] branch crichter/0.3.0 - r7651 in /team/crichter/0.3.0: ./ apps/ cdr/ channels...

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Tue Dec 27 04:24:23 CST 2005


Author: crichter
Date: Tue Dec 27 04:23:55 2005
New Revision: 7651

URL: http://svn.digium.com/view/asterisk?rev=7651&view=rev
Log:
Merged revisions 7565-7570,7573-7576,7578-7579,7583,7587,7589-7590,7594,7600,7602,7604,7607,7609,7613-7620,7627,7633,7635-7636,7638-7640,7642-7643,7646-7649 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r7565 | markster | 2005-12-21 00:36:22 +0100 (Mi, 21 Dez 2005) | 2 lines

Avoid multiple free 

................
r7566 | jdixon | 2005-12-21 00:41:59 +0100 (Mi, 21 Dez 2005) | 2 lines

New version, including half/semi-half duplex modes and system announcements

................
r7567 | jdixon | 2005-12-21 00:53:26 +0100 (Mi, 21 Dez 2005) | 2 lines

Added docs for new features (duplex mode & tailmessages)

................
r7568 | russell | 2005-12-21 09:44:51 +0100 (Mi, 21 Dez 2005) | 4 lines

- change the default value of the global priority jumping option to 'off'
- update the UPGRADE.txt file to reflect this change
- remove old information from UPGRADE.txt

................
r7569 | russell | 2005-12-21 09:51:44 +0100 (Mi, 21 Dez 2005) | 4 lines

add a header to indicate who the call was parked by to the ParkedCall manager
events generated when parking status is requested.  This header was already
in the events that are generated when the call is first parked. (issue #5883)

................
r7570 | russell | 2005-12-21 10:33:41 +0100 (Mi, 21 Dez 2005) | 2 lines

add Log application for generating custom log messages from the dialplan (issue #5287)

................
r7573 | tilghman | 2005-12-21 16:16:08 +0100 (Mi, 21 Dez 2005) | 2 lines

Bug 5734 - add status variables indicating the success or failure of the realtime apps

................
r7574 | russell | 2005-12-21 17:36:48 +0100 (Mi, 21 Dez 2005) | 2 lines

move heading to the top of the file

................
r7575 | tilghman | 2005-12-21 18:09:54 +0100 (Mi, 21 Dez 2005) | 2 lines

Bug 5440 - Add STAT() dialplan function

................
r7576 | tilghman | 2005-12-21 19:43:10 +0100 (Mi, 21 Dez 2005) | 2 lines

Bug 5055 - Simple SQL commands from the dialplan

................
r7578 | tilghman | 2005-12-21 20:24:56 +0100 (Mi, 21 Dez 2005) | 3 lines

Merged revisions 7577 via svnmerge from
/branches/1.2

................
r7579 | bweschke | 2005-12-21 20:44:51 +0100 (Mi, 21 Dez 2005) | 3 lines

 Bug #6040 - Documentation correction


................
r7583 | tilghman | 2005-12-21 21:02:36 +0100 (Mi, 21 Dez 2005) | 3 lines

Merged revisions 7582 via svnmerge from
/branches/1.2

................
r7587 | russell | 2005-12-22 03:20:44 +0100 (Do, 22 Dez 2005) | 7 lines

- construct the difference and have only one call to snprintf in build_via
- convert some while loops to for loops
- localize some variables and remove unneeded initializations
- store result of get_header locally so it only has to be called once
- remove some duplicate calls to strcasecmp by storing result
(issue #5955)

................
r7589 | kpfleming | 2005-12-22 04:49:41 +0100 (Do, 22 Dez 2005) | 2 lines

don't try to build func_odbc when ODBC headers/libraries are not present

................
r7590 | kpfleming | 2005-12-22 04:50:44 +0100 (Do, 22 Dez 2005) | 2 lines

forward-port per-peer videosupport changes from branches/1.2

................
r7594 | russell | 2005-12-22 17:14:38 +0100 (Do, 22 Dez 2005) | 2 lines

remove stray unlock (issue #5955)

................
r7600 | russell | 2005-12-22 21:38:43 +0100 (Do, 22 Dez 2005) | 11 lines

Merged revisions 7599 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r7599 | russell | 2005-12-22 15:36:47 -0500 (Thu, 22 Dec 2005) | 3 lines

revert changes to videosupport to allow per-peer setting, since it isn't quite
complete and there is not an obvious fix at this point

........

................
r7602 | tilghman | 2005-12-22 23:06:35 +0100 (Do, 22 Dez 2005) | 3 lines

Merged revisions 7601 via svnmerge from
/branches/1.2

................
r7604 | bweschke | 2005-12-23 00:59:13 +0100 (Fr, 23 Dez 2005) | 3 lines

 Another app documentation tweak.


................
r7607 | kpfleming | 2005-12-23 04:04:38 +0100 (Fr, 23 Dez 2005) | 11 lines

Merged revisions 7606 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r7606 | kpfleming | 2005-12-22 21:01:24 -0600 (Thu, 22 Dec 2005) | 3 lines

add license reference to copyright notice displayed when CLI session begins
add 'show warranty' and 'show license' CLI commands (still need a complete list of non-GPL components included in Asterisk)

........

................
r7609 | tilghman | 2005-12-23 07:39:44 +0100 (Fr, 23 Dez 2005) | 3 lines

Merged revisions 7608 via svnmerge from
/branches/1.2

................
r7613 | tilghman | 2005-12-23 21:43:11 +0100 (Fr, 23 Dez 2005) | 2 lines

Make the English language of date format 'Q' and 'q' sound a little bit more natural

................
r7614 | tilghman | 2005-12-23 22:03:25 +0100 (Fr, 23 Dez 2005) | 2 lines

Bug 5327 - new function FILTER and optional argument to CALLERID

................
r7615 | tilghman | 2005-12-23 23:47:26 +0100 (Fr, 23 Dez 2005) | 2 lines

Alphabetize the functions list

................
r7616 | tilghman | 2005-12-24 00:42:58 +0100 (Sa, 24 Dez 2005) | 2 lines

Bug 5759 - Remove unused datetime code (current DateTime app is in app_sayunixtime)

................
r7617 | russell | 2005-12-24 06:18:40 +0100 (Sa, 24 Dez 2005) | 5 lines

minor cleanups ...
- use for loops instead of while loops for basic list traversals
- remove an unused 'res' variable
- formatting tweaks

................
r7618 | russell | 2005-12-24 07:23:36 +0100 (Sa, 24 Dez 2005) | 7 lines

minor cleanups ...
- use for loops instead of while loops for basic list traversals
- only calculate word length one time in CLI complete functions
- use calloc instead of malloc + memset
- remove some unnecessary casts
- formatting tweaks 

................
r7619 | tilghman | 2005-12-25 01:25:41 +0100 (So, 25 Dez 2005) | 2 lines

Bug 5727 - reduce duplicate code

................
r7620 | markster | 2005-12-25 02:27:47 +0100 (So, 25 Dez 2005) | 2 lines

Fix multiple free of a frame (bug #6058)

................
r7627 | markster | 2005-12-26 01:47:28 +0100 (Mo, 26 Dez 2005) | 3 lines

Add "local channel" variation so that we don't read/write to the same 
channel...  (bug #6058)

................
r7633 | tilghman | 2005-12-26 17:48:12 +0100 (Mo, 26 Dez 2005) | 2 lines

Bug 6057 - Deprecate builtins that have been replaced by functions

................
r7635 | russell | 2005-12-26 19:35:28 +0100 (Mo, 26 Dez 2005) | 10 lines

Merged revisions 7634 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r7634 | russell | 2005-12-26 13:19:12 -0500 (Mon, 26 Dec 2005) | 2 lines

cast time_t to an int in printf/scanf (issue #5635)

........

................
r7636 | jdixon | 2005-12-26 21:01:35 +0100 (Mo, 26 Dez 2005) | 3 lines

Added support for Feature Group C CAMA trunks (both DP and MF), and support
for Feature Group D Tamdem trunks inbound (outbound was already there)

................
r7638 | tilghman | 2005-12-26 21:34:46 +0100 (Mo, 26 Dez 2005) | 3 lines

Merged revisions 7637 via svnmerge from
/branches/1.2

................
r7639 | russell | 2005-12-26 22:38:50 +0100 (Mo, 26 Dez 2005) | 5 lines

- normalize some loops
- simplify and reduce code by keeping track of return value
- replace some simple if/then sections with conditional expressions
(issue #6065)

................
r7640 | markster | 2005-12-27 00:56:44 +0100 (Di, 27 Dez 2005) | 2 lines

Don't do DTMF detect on pseudo's!

................
r7642 | tilghman | 2005-12-27 03:02:23 +0100 (Di, 27 Dez 2005) | 2 lines

Add SQL_ESC to allow single ticks to be escaped

................
r7643 | tilghman | 2005-12-27 03:05:56 +0100 (Di, 27 Dez 2005) | 2 lines

Reduce warnings on signedness conversions

................
r7646 | tilghman | 2005-12-27 07:24:28 +0100 (Di, 27 Dez 2005) | 2 lines

Bug 5183 - Inline stack backtraces

................
r7647 | tilghman | 2005-12-27 07:42:29 +0100 (Di, 27 Dez 2005) | 2 lines

Bug 5854 - Allow quotation of the second field in extconfig, for the purpose of including commas (for LDAP configuration)

................
r7648 | tilghman | 2005-12-27 07:50:25 +0100 (Di, 27 Dez 2005) | 2 lines

Bug 5906 - ARRAY dialplan function

................
r7649 | tilghman | 2005-12-27 08:13:37 +0100 (Di, 27 Dez 2005) | 2 lines

Bug 5382 - Allow VM_CATEGORY in voicemail emails

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

Added:
    team/crichter/0.3.0/configs/func_odbc.conf.sample
      - copied unchanged from r7649, trunk/configs/func_odbc.conf.sample
    team/crichter/0.3.0/funcs/func_odbc.c
      - copied unchanged from r7649, trunk/funcs/func_odbc.c
Removed:
    team/crichter/0.3.0/apps/app_datetime.c
Modified:
    team/crichter/0.3.0/   (props changed)
    team/crichter/0.3.0/Makefile
    team/crichter/0.3.0/UPGRADE.txt
    team/crichter/0.3.0/apps/Makefile
    team/crichter/0.3.0/apps/app_chanspy.c
    team/crichter/0.3.0/apps/app_externalivr.c
    team/crichter/0.3.0/apps/app_hasnewvoicemail.c
    team/crichter/0.3.0/apps/app_meetme.c
    team/crichter/0.3.0/apps/app_queue.c
    team/crichter/0.3.0/apps/app_realtime.c
    team/crichter/0.3.0/apps/app_rpt.c
    team/crichter/0.3.0/apps/app_sms.c
    team/crichter/0.3.0/apps/app_verbose.c
    team/crichter/0.3.0/apps/app_voicemail.c
    team/crichter/0.3.0/apps/app_waitforsilence.c
    team/crichter/0.3.0/asterisk.c
    team/crichter/0.3.0/cdr/cdr_tds.c
    team/crichter/0.3.0/channel.c
    team/crichter/0.3.0/channels/chan_agent.c
    team/crichter/0.3.0/channels/chan_alsa.c
    team/crichter/0.3.0/channels/chan_iax2.c
    team/crichter/0.3.0/channels/chan_sip.c
    team/crichter/0.3.0/channels/chan_zap.c
    team/crichter/0.3.0/cli.c
    team/crichter/0.3.0/config.c
    team/crichter/0.3.0/configs/agents.conf.sample
    team/crichter/0.3.0/configs/extconfig.conf.sample
    team/crichter/0.3.0/configs/rpt.conf.sample
    team/crichter/0.3.0/configs/sip.conf.sample
    team/crichter/0.3.0/configs/zapata.conf.sample
    team/crichter/0.3.0/funcs/Makefile
    team/crichter/0.3.0/funcs/func_callerid.c
    team/crichter/0.3.0/funcs/func_env.c
    team/crichter/0.3.0/funcs/func_strings.c
    team/crichter/0.3.0/include/asterisk/logger.h
    team/crichter/0.3.0/include/asterisk/pbx.h
    team/crichter/0.3.0/logger.c
    team/crichter/0.3.0/pbx.c
    team/crichter/0.3.0/pbx/pbx_ael.c
    team/crichter/0.3.0/pbx/pbx_dundi.c
    team/crichter/0.3.0/res/res_features.c
    team/crichter/0.3.0/res/res_monitor.c
    team/crichter/0.3.0/say.c

Propchange: team/crichter/0.3.0/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Dec 27 04:23:55 2005
@@ -1,1 +1,1 @@
-/trunk:1-7563
+/trunk:1-7650

Modified: team/crichter/0.3.0/Makefile
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/Makefile?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/Makefile (original)
+++ team/crichter/0.3.0/Makefile Tue Dec 27 04:23:55 2005
@@ -45,6 +45,11 @@
 
 #Tell gcc to optimize the code
 OPTIMIZE+=-O6
+else
+  # Stack backtraces, while useful for debugging, are incompatible with optimizations
+  ifeq (${OSARCH},Linux)
+    CFLAGS+=-DSTACK_BACKTRACES
+  endif
 endif
 
 #Overwite config files on "make samples"
@@ -332,7 +337,10 @@
 ASTCFLAGS+= $(MALLOC_DEBUG)
 ASTCFLAGS+= $(BUSYDETECT)
 ASTCFLAGS+= $(OPTIONS)
+ifneq ($(findstring dont-optimize,$(MAKECMDGOALS)),dont-optimize)
 ASTCFLAGS+= -fomit-frame-pointer 
+endif
+
 SUBDIRS=res channels pbx apps codecs formats agi cdr funcs utils stdtime
 
 OBJS=io.o sched.o logger.o frame.o loader.o config.o channel.o \

Modified: team/crichter/0.3.0/UPGRADE.txt
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/UPGRADE.txt?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/UPGRADE.txt (original)
+++ team/crichter/0.3.0/UPGRADE.txt Tue Dec 27 04:23:55 2005
@@ -1,205 +1,28 @@
 Information for Upgrading From Previous Asterisk Releases
 =========================================================
 
-Compiling:
-
-* The Asterisk 1.2 source code now uses C language features
-  supported only by 'modern' C compilers.  Generally, this means GCC
-  version 3.0 or higher, although some GCC 2.96 releases will also
-  work.  Some non-GCC compilers that support C99 and the common GCC
-  extensions (including anonymous structures and unions) will also
-  work.  All releases of GCC 2.95 do _not_ have the requisite feature
-  support; systems using that compiler will need to be upgraded to
-  a more recent compiler release.
-
-Dialplan Expressions:
-
-* The dialplan expression parser (which handles $[ ... ] constructs)
-  has gone through a major upgrade, but has one incompatible change:
-  spaces are no longer required around expression operators, including
-  string comparisons. However, you can now use quoting to keep strings
-  together for comparison. For more details, please read the
-  doc/README.variables file, and check over your dialplan for possible
-  problems.
-
-Agents:
-
-* The default for ackcall has been changed to "no" instead of "yes" 
-  because of a bug which caused the "yes" behavior to generally act like
-  "no".  You may need to adjust the value if your agents behave 
-  differently than you expect with respect to acknowledgement.
-
-* The AgentCallBackLogin application now requires a second '|' before
-  specifying an extension at context.  This is to distinguish the options
-  string from the extension, so that they do not conflict.  See
-  'show application AgentCallbackLogin' for more details.
-
-Parking:
-
-* Parking behavior has changed slightly; when a parked call times out,
-  Asterisk will attempt to deliver the call back to the extension that
-  parked it, rather than the 's' extension. If that extension is busy
-  or unavailable, the parked call will be lost.
-
-Dialing:
-
-* The Caller*ID of the outbound leg is now the extension that was 
-  called, rather than the Caller*ID of the inbound leg of the call.  The 
-  "o" flag for Dial can be used to restore the original behavior if 
-  desired.  Note that if you are looking for the originating callerid
-  from the manager event, there is a new manager event "Dial" which 
-  provides the source and destination channels and callerid.
-
-IAX: 
-
-* The naming convention for IAX channels has changed in two ways: 
-   1. The call number follows a "-" rather than a "/" character.
-   2. The name of the channel has been simplified to IAX2/peer-callno,
-   rather than IAX2/peer at peer-callno or even IAX2/peer at peer/callno.
-
-SIP:
-
-* The global option "port" in 1.0.X that is used to set which port to
-  bind to has been changed to "bindport" to be more consistent with
-  the other channel drivers and to avoid confusion with the "port"
-  option for users/peers.
-
-* The "Registry" event now uses "Username" rather than "User" for 
-  consistency with IAX.
-
 Applications:
 
-* With the addition of dialplan functions (which operate similarly
-  to variables), the SetVar application has been renamed to Set.
+* In previous Asterisk releases, many applications would jump to priority n+101
+  to indicate some kind of status or error condition.  This functionality was
+  marked deprecated in Asterisk 1.2.  An option to disable it was provided with
+  the default value set to 'on'.  The default value for the global priority
+  jumping option is now 'off'.
 
-* The CallerPres application has been removed.  Use SetCallerPres 
-  instead.  It accepts both numeric and symbolic names.
+* The applications Cut, Sort, DBGet, DBPut, SetCIDNum, SetCIDName, SetRDNIS,
+  AbsoluteTimeout, DigitTimeout, ResponseTimeout, SetLanguage, GetGroupCount,
+  and GetGroupMatchCount were all deprecated in version 1.2, and therefore have
+  been removed in this version.  You should use the equivalent dialplan
+  function in places where you have previously used one of these applications.
 
-* The applications GetGroupCount, GetGroupMatchCount, SetGroup, and
-  CheckGroup have been deprecated in favor of functions.  Here is a
-  table of their replacements:
+* The application SetVar has been renamed to Set.  The syntax SetVar was marked
+  deprecated in version 1.2 and is no longer recognized in this version.
 
-  GetGroupCount([groupname][@category]	       GROUP_COUNT([groupname][@category])	Set(GROUPCOUNT=${GROUP_COUNT()})
-  GroupMatchCount(groupmatch[@category])       GROUP_MATCH_COUNT(groupmatch[@category])	Set(GROUPCOUNT=${GROUP_MATCH_COUNT(SIP/.*)})
-  SetGroup(groupname[@category])	       GROUP([category])=groupname		Set(GROUP()=test)
-  CheckGroup(max[@category])		       N/A					GotoIf($[ ${GROUP_COUNT()} > 5 ]?103)
+Variables:
 
-  Note that CheckGroup does not have a direct replacement.  There is
-  also a new function called GROUP_LIST() which will return a space
-  separated list of all of the groups set on a channel.  The GROUP()
-  function can also return the name of the group set on a channel when
-  used in a read environment.
+* The builtin variables ${CALLERID}, ${CALLERIDNAME}, ${CALLERIDNUM},
+  ${CALLERANI}, ${DNID}, ${RDNIS}, ${DATETIME}, ${TIMESTAMP}, ${ACCOUNTCODE},
+  and ${LANGUAGE} have all been deprecated in favor of their related dialplan
+  functions.  You are encouraged to move towards the associated dialplan
+  function, as these variables will be removed in a future release.
 
-* The applications DBGet and DBPut have been deprecated in favor of
-  functions.  Here is a table of their replacements:
-
-  DBGet(foo=family/key)        Set(foo=${DB(family/key)})
-  DBPut(family/key=${foo})     Set(DB(family/key)=${foo})
-
-* The application SetLanguage has been deprecated in favor of the
-  function LANGUAGE().
-
-  SetLanguage(fr)		Set(LANGUAGE()=fr)
-
-  The LANGUAGE function can also return the currently set language:
-
-  Set(MYLANG=${LANGUAGE()})
-
-* The applications AbsoluteTimeout, DigitTimeout, and ResponseTimeout
-  have been deprecated in favor of the function TIMEOUT(timeouttype):
-
-  AbsoluteTimeout(300)		Set(TIMEOUT(absolute)=300)
-  DigitTimeout(15)		Set(TIMEOUT(digit)=15)
-  ResponseTimeout(15)		Set(TIMEOUT(response)=15)
-
-  The TIMEOUT() function can also return the currently set timeouts:
-
-  Set(DTIMEOUT=${TIMEOUT(digit)})
-
-* The applications SetCIDName, SetCIDNum, and SetRDNIS have been
-  deprecated in favor of the CALLERID(datatype) function:
-
-  SetCIDName(Joe Cool)		Set(CALLERID(name)=Joe Cool)
-  SetCIDNum(2025551212)		Set(CALLERID(number)=2025551212)
-  SetRDNIS(2024561414)		Set(CALLERID(RDNIS)=2024561414)
-
-* The application Record now uses the period to separate the filename
-  from the format, rather than the colon.
-
-* The application VoiceMail now supports a 'temporary' greeting for each
-  mailbox. This greeting can be recorded by using option 4 in the
-  'mailbox options' menu, and 'change your password' option has been
-  moved to option 5.
-
-* The application VoiceMailMain now only matches the 'default' context if
-  none is specified in the arguments.  (This was the previously 
-  documented behavior, however, we didn't follow that behavior.)  The old
-  behavior can be restored by setting searchcontexts=yes in voicemail.conf.
-
-Queues:
-
-* A queue is now considered empty not only if there are no members but if
-  none of the members are available (e.g. agents not logged on).  To
-  restore the original behavior, use "leavewhenempty=strict" or 
-  "joinwhenempty=strict" instead of "=yes" for those options.
-
-* It is now possible to use multi-digit extensions in the exit context
-  for a queue (although you should not have overlapping extensions,
-  as there is no digit timeout). This means that the EXITWITHKEY event
-  in queue_log can now contain a key field with more than a single
-  character in it.
-
-Extensions:
-
-* By default, there is a new option called "autofallthrough" in
-  extensions.conf that is set to yes.  Asterisk 1.0 (and earlier) 
-  behavior was to wait for an extension to be dialed after there were no 
-  more extensions to execute.  "autofallthrough" changes this behavior
-  so that the call will immediately be terminated with BUSY,
-  CONGESTION, or HANGUP based on Asterisk's best guess.  If you are
-  writing an extension for IVR, you must use the WaitExten application
-  if "autofallthrough" is set to yes.
-
-AGI:
-
-* AGI scripts did not always get SIGHUP at the end, previously.  That 
-  behavior has been fixed.  If you do not want your script to terminate 
-  at the end of AGI being called (e.g. on a hangup) then set SIGHUP to 
-  be ignored within your application.
-
-* CallerID is reported with agi_callerid and agi_calleridname instead
-  of a single parameter holding both.
-
-Music On Hold:
-
-* The preferred format for musiconhold.conf has changed; please see the
-  sample configuration file for the new format. The existing format
-  is still supported but will generate warnings when the module is loaded.
-
-chan_modem:
-
-* All the chan_modem channel drivers (aopen, bestdata and i4l) are deprecated
-  in this release, and will be removed in the next major Asterisk release.
-  Please migrate to chan_misdn for ISDN interfaces; there is no upgrade
-  path for aopen and bestdata modem users.
-
-MeetMe:
-
-* The conference application now allows users to increase/decrease their
-  speaking volume and listening volume (independently of each other and 
-  other users); the 'admin' and 'user' menus have changed, and new sound 
-  files are included with this release. However, if a user calling in 
-  over a Zaptel channel that does NOT have hardware DTMF detection 
-  increases their speaking volume, it is likely they will no longer be 
-  able to enter/exit the menu or make any further adjustments, as the  
-  software DTMF detector will not be able to recognize the DTMF coming 
-  from their device.
-
-GetVar Manager Action:
-
-* Previously, the behavior of the GetVar manager action reported the value
-  of a variable in the following manner:
-   > name: value
-  This has been changed to a manner similar to the SetVar action and is now
-   > Variable: name
-   > Value: value

Modified: team/crichter/0.3.0/apps/Makefile
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/Makefile?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/Makefile (original)
+++ team/crichter/0.3.0/apps/Makefile Tue Dec 27 04:23:55 2005
@@ -91,6 +91,7 @@
 
 install: all
 	for x in $(APPS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
+	rm -f $(DESTDIR)$(MODULES_DIR)/app_cut.so
 	rm -f $(DESTDIR)$(MODULES_DIR)/app_datetime.so
 	rm -f $(DESTDIR)$(MODULES_DIR)/app_qcall.so
 

Modified: team/crichter/0.3.0/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_chanspy.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_chanspy.c (original)
+++ team/crichter/0.3.0/apps/app_chanspy.c Tue Dec 27 04:23:55 2005
@@ -439,7 +439,7 @@
 
 	if (recbase) {
 		char filename[512];
-		snprintf(filename,sizeof(filename),"%s/%s.%ld.raw",ast_config_AST_MONITOR_DIR, recbase, time(NULL));
+		snprintf(filename,sizeof(filename),"%s/%s.%d.raw",ast_config_AST_MONITOR_DIR, recbase, (int)time(NULL));
 		if ((fd = open(filename, O_CREAT | O_WRONLY, O_TRUNC)) <= 0) {
 			ast_log(LOG_WARNING, "Cannot open %s for recording\n", filename);
 			fd = 0;

Modified: team/crichter/0.3.0/apps/app_externalivr.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_externalivr.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_externalivr.c (original)
+++ team/crichter/0.3.0/apps/app_externalivr.c Tue Dec 27 04:23:55 2005
@@ -94,9 +94,9 @@
 	char tmp[256];
 
 	if (!data) {
-		snprintf(tmp, sizeof(tmp), "%c,%10ld", event, time(NULL));
+		snprintf(tmp, sizeof(tmp), "%c,%10d", event, (int)time(NULL));
 	} else {
-		snprintf(tmp, sizeof(tmp), "%c,%10ld,%s", event, time(NULL), data);
+		snprintf(tmp, sizeof(tmp), "%c,%10d,%s", event, (int)time(NULL), data);
 	}
 
 	fprintf(handle, "%s\n", tmp);

Modified: team/crichter/0.3.0/apps/app_hasnewvoicemail.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_hasnewvoicemail.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_hasnewvoicemail.c (original)
+++ team/crichter/0.3.0/apps/app_hasnewvoicemail.c Tue Dec 27 04:23:55 2005
@@ -90,7 +90,6 @@
 		while ((vment = readdir(vmdir))) {
 			if (!strncmp(vment->d_name + 7, ".txt", 4)) {
 				count++;
-				break;
 			}
 		}
 		closedir(vmdir);

Modified: team/crichter/0.3.0/apps/app_meetme.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_meetme.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_meetme.c (original)
+++ team/crichter/0.3.0/apps/app_meetme.c Tue Dec 27 04:23:55 2005
@@ -139,6 +139,7 @@
 	ast_mutex_t listenlock;				/* Conference specific lock (listeners) */
 	char confno[AST_MAX_EXTENSION];		/* Conference */
 	struct ast_channel *chan;		/* Announcements channel */
+	struct ast_channel *lchan;		/* Listen/Record channel */
 	int fd;					/* Announcements fd */
 	int zapconf;				/* Zaptel Conf # */
 	int users;				/* Number of active users */
@@ -509,7 +510,18 @@
 				cnf = NULL;
 				goto cnfout;
 			}
-
+			cnf->lchan = ast_request("zap", AST_FORMAT_SLINEAR, "pseudo", NULL);
+			if (cnf->lchan) {
+				ast_set_read_format(cnf->lchan, AST_FORMAT_SLINEAR);
+				ast_set_write_format(cnf->lchan, AST_FORMAT_SLINEAR);
+				ztc.chan = 0;
+				ztc.confmode = ZT_CONF_CONFANN | ZT_CONF_CONFANNMON;
+				if (ioctl(cnf->lchan->fds[0], ZT_SETCONF, &ztc)) {
+					ast_log(LOG_WARNING, "Error setting conference\n");
+					ast_hangup(cnf->lchan);
+					cnf->lchan = NULL;
+				}
+			}
 			/* Fill the conference struct */
 			cnf->start = time(NULL);
 			cnf->zapconf = ztc.confno;
@@ -813,9 +825,11 @@
 			ast_frfree(conf->transframe[x]);
 		if (conf->transpath[x])
 			ast_translator_free_path(conf->transpath[x]);
-		if (conf->origframe)
-			ast_frfree(conf->origframe);
-	}
+	}
+	if (conf->origframe)
+		ast_frfree(conf->origframe);
+	if (conf->lchan)
+		ast_hangup(conf->lchan);
 	if (conf->chan)
 		ast_hangup(conf->chan);
 	else
@@ -885,7 +899,7 @@
 		}
 	}
 
-	if ((conf->recording == MEETME_RECORD_OFF) && ((confflags & CONFFLAG_RECORDCONF) || (conf->chan))) {
+	if ((conf->recording == MEETME_RECORD_OFF) && ((confflags & CONFFLAG_RECORDCONF) || (conf->lchan))) {
 		pthread_attr_init(&conf->attr);
 		pthread_attr_setdetachstate(&conf->attr, PTHREAD_CREATE_DETACHED);
 		ast_pthread_create(&conf->recordthread, &conf->attr, recordthread, conf);
@@ -2231,16 +2245,16 @@
 	int x;
 	const char *oldrecordingfilename = NULL;
 
-	if (!cnf || !cnf->chan) {
+	if (!cnf || !cnf->lchan) {
 		pthread_exit(0);
 	}
 
-	ast_stopstream(cnf->chan);
+	ast_stopstream(cnf->lchan);
 	flags = O_CREAT|O_TRUNC|O_WRONLY;
 
 
 	cnf->recording = MEETME_RECORD_ACTIVE;
-	while (ast_waitfor(cnf->chan, -1) > -1) {
+	while (ast_waitfor(cnf->lchan, -1) > -1) {
 		if (cnf->recording == MEETME_RECORD_TERMINATE) {
 			ast_mutex_lock(&conflock);
 			ast_mutex_unlock(&conflock);
@@ -2251,7 +2265,7 @@
 			oldrecordingfilename = cnf->recordingfilename;
 		}
 		
-		f = ast_read(cnf->chan);
+		f = ast_read(cnf->lchan);
 		if (!f) {
 			res = -1;
 			break;
@@ -2264,10 +2278,10 @@
 					ast_frfree(cnf->transframe[x]);
 					cnf->transframe[x] = NULL;
 				}
-				if (cnf->origframe)
-					ast_frfree(cnf->origframe);
-				cnf->origframe = f;
-			}
+			}
+			if (cnf->origframe)
+				ast_frfree(cnf->origframe);
+			cnf->origframe = f;
 			ast_mutex_unlock(&cnf->listenlock);
 			if (s)
 				res = ast_writestream(s, f);

Modified: team/crichter/0.3.0/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_queue.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_queue.c (original)
+++ team/crichter/0.3.0/apps/app_queue.c Tue Dec 27 04:23:55 2005
@@ -484,11 +484,11 @@
 							"Membership: %s\r\n"
 							"Penalty: %d\r\n"
 							"CallsTaken: %d\r\n"
-							"LastCall: %ld\r\n"
+							"LastCall: %d\r\n"
 							"Status: %d\r\n"
 							"Paused: %d\r\n",
 						q->name, cur->interface, cur->dynamic ? "dynamic" : "static",
-						cur->penalty, cur->calls, cur->lastcall, cur->status, cur->paused);
+						cur->penalty, cur->calls, (int)cur->lastcall, cur->status, cur->paused);
 					}
 				}
 			}
@@ -1262,11 +1262,11 @@
 					"Membership: %s\r\n"
 					"Penalty: %d\r\n"
 					"CallsTaken: %d\r\n"
-					"LastCall: %ld\r\n"
+					"LastCall: %d\r\n"
 					"Status: %d\r\n"
 					"Paused: %d\r\n",
 				q->name, cur->interface, cur->dynamic ? "dynamic" : "static",
-				cur->penalty, cur->calls, cur->lastcall, cur->status, cur->paused);
+				cur->penalty, cur->calls, (int)cur->lastcall, cur->status, cur->paused);
 			}
 			break;
 		}
@@ -2421,11 +2421,11 @@
 						"Membership: %s\r\n"
 						"Penalty: %d\r\n"
 						"CallsTaken: %d\r\n"
-						"LastCall: %ld\r\n"
+						"LastCall: %d\r\n"
 						"Status: %d\r\n"
 						"Paused: %d\r\n",
 					q->name, new_member->interface, new_member->dynamic ? "dynamic" : "static",
-					new_member->penalty, new_member->calls, new_member->lastcall, new_member->status, new_member->paused);
+					new_member->penalty, new_member->calls, (int)new_member->lastcall, new_member->status, new_member->paused);
 					
 					if (dump)
 						dump_queue_members(q);
@@ -3435,13 +3435,13 @@
 						"Membership: %s\r\n"
 						"Penalty: %d\r\n"
 						"CallsTaken: %d\r\n"
-						"LastCall: %ld\r\n"
+						"LastCall: %d\r\n"
 						"Status: %d\r\n"
 						"Paused: %d\r\n"
 						"%s"
 						"\r\n",
 							q->name, mem->interface, mem->dynamic ? "dynamic" : "static",
-							mem->penalty, mem->calls, mem->lastcall, mem->status, mem->paused, idText);
+							mem->penalty, mem->calls, (int)mem->lastcall, mem->status, mem->paused, idText);
 				}
 			}
 			/* List Queue Entries */

Modified: team/crichter/0.3.0/apps/app_realtime.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_realtime.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_realtime.c (original)
+++ team/crichter/0.3.0/apps/app_realtime.c Tue Dec 27 04:23:55 2005
@@ -53,13 +53,18 @@
 static char *usynopsis = "Realtime Data Rewrite";
 static char *USAGE = "RealTime(<family>|<colmatch>|<value>[|<prefix>])";
 static char *UUSAGE = "RealTimeUpdate(<family>|<colmatch>|<value>|<newcol>|<newval>)";
-static char *desc = "Use the RealTime config handler system to read data into channel variables.\n"
+static char *desc =
+"Use the RealTime config handler system to read data into channel variables.\n"
 "RealTime(<family>|<colmatch>|<value>[|<prefix>])\n\n"
-"All unique column names will be set as channel variables with optional prefix to the name.\n"
-"e.g. prefix of 'var_' would make the column 'name' become the variable ${var_name}\n\n";
+"All unique column names will be set as channel variables with optional prefix\n"
+"to the name.  For example, a prefix of 'var_' would make the column 'name'\n"
+"become the variable ${var_name}.  REALTIMECOUNT will be set with the number\n"
+"of values read.\n";
 static char *udesc = "Use the RealTime config handler system to update a value\n"
 "RealTimeUpdate(<family>|<colmatch>|<value>|<newcol>|<newval>)\n\n"
-"The column <newcol> in 'family' matching column <colmatch>=<value> will be updated to <newval>\n";
+"The column <newcol> in 'family' matching column <colmatch>=<value> will be\n"
+"updated to <newval>.  REALTIMECOUNT will be set with the number of rows\n"
+"updated or -1 if an error occurs.\n";
 
 STANDARD_LOCAL_USER;
 LOCAL_USER_DECL;
@@ -130,7 +135,8 @@
 {
 	char *family=NULL, *colmatch=NULL, *value=NULL, *newcol=NULL, *newval=NULL;
 	struct localuser *u;
-	int res = 0;
+	int res = 0, count = 0;
+	char countc[13];
 
 	if (ast_strlen_zero(data)) {
 		ast_log(LOG_ERROR,"Invalid input: usage %s\n",UUSAGE);
@@ -156,8 +162,11 @@
 		ast_log(LOG_ERROR,"Invalid input: usage %s\n",UUSAGE);
 		res = -1;
 	} else {
-		ast_update_realtime(family,colmatch,value,newcol,newval,NULL);
-	}
+		count = ast_update_realtime(family,colmatch,value,newcol,newval,NULL);
+	}
+
+	snprintf(countc, sizeof(countc), "%d", count);
+	pbx_builtin_setvar_helper(chan, "REALTIMECOUNT", countc);
 
 	LOCAL_USER_REMOVE(u);
 	
@@ -167,10 +176,11 @@
 
 static int realtime_exec(struct ast_channel *chan, void *data)
 {
-	int res=0;
+	int res=0, count=0;
 	struct localuser *u;
 	struct ast_variable *var, *itt;
 	char *family=NULL, *colmatch=NULL, *value=NULL, *prefix=NULL, *vname=NULL;
+	char countc[13];
 	size_t len;
 		
 	if (ast_strlen_zero(data)) {
@@ -207,11 +217,14 @@
 					vname = itt->name;
 
 				pbx_builtin_setvar_helper(chan, vname, itt->value);
+				count++;
 			}
 			ast_variables_destroy(var);
 		} else if (option_verbose > 3)
 			ast_verbose(VERBOSE_PREFIX_4"No Realtime Matches Found.\n");
 	}
+	snprintf(countc, sizeof(countc), "%d", count);
+	pbx_builtin_setvar_helper(chan, "REALTIMECOUNT", countc);
 	
 	LOCAL_USER_REMOVE(u);
 	return res;

Modified: team/crichter/0.3.0/apps/app_rpt.c
URL: http://svn.digium.com/view/asterisk/team/crichter/0.3.0/apps/app_rpt.c?rev=7651&r1=7650&r2=7651&view=diff
==============================================================================
--- team/crichter/0.3.0/apps/app_rpt.c (original)
+++ team/crichter/0.3.0/apps/app_rpt.c Tue Dec 27 04:23:55 2005
@@ -20,7 +20,7 @@
 /*
  *
  * Radio Repeater / Remote Base program 
- *  version 0.37 11/3/05
+ *  version 0.39 12/19/05
  * 
  * See http://www.zapatatelephony.org/app_rpt.html
  *
@@ -114,6 +114,9 @@
 
 #define	MAXREMSTR 15
 
+#define	DELIMCHR ','
+#define	QUOTECHR 34
+
 #define	NODES "nodes"
 #define MEMORY "memory"
 #define	FUNCTIONS "functions"
@@ -139,7 +142,8 @@
 
 enum{ID,PROC,TERM,COMPLETE,UNKEY,REMDISC,REMALREADY,REMNOTFOUND,REMGO,
 	CONNECTED,CONNFAIL,STATUS,TIMEOUT,ID1, STATS_TIME,
-	STATS_VERSION, IDTALKOVER, ARB_ALPHA, TEST_TONE, REV_PATCH};
+	STATS_VERSION, IDTALKOVER, ARB_ALPHA, TEST_TONE, REV_PATCH,
+	TAILMSG};
 
 enum {REM_SIMPLEX,REM_MINUS,REM_PLUS};
 
@@ -153,7 +157,8 @@
 
 enum {REM_MODE_FM,REM_MODE_USB,REM_MODE_LSB,REM_MODE_AM};
 
-enum {HF_SCAN_OFF,HF_SCAN_DOWN_SLOW,HF_SCAN_DOWN_QUICK,HF_SCAN_DOWN_FAST,HF_SCAN_UP_SLOW,HF_SCAN_UP_QUICK,HF_SCAN_UP_FAST};
+enum {HF_SCAN_OFF,HF_SCAN_DOWN_SLOW,HF_SCAN_DOWN_QUICK,
+      HF_SCAN_DOWN_FAST,HF_SCAN_UP_SLOW,HF_SCAN_UP_QUICK,HF_SCAN_UP_FAST};
 
 #include "asterisk.h"
 
@@ -197,7 +202,7 @@
 #include "asterisk/say.h"
 #include "asterisk/localtime.h"
 
-static  char *tdesc = "Radio Repeater / Remote Base  version 0.37  11/03/2005";
+static  char *tdesc = "Radio Repeater / Remote Base  version 0.39  12/19/2005";
 
 static char *app = "Rpt";
 
@@ -341,6 +346,7 @@
 	int totime;
 	int idtime;
 	int unkeytocttimer;
+	int duplex;
 	char keyed;
 	char exttx;
 	char localtx;
@@ -360,7 +366,7 @@
 	struct rpt_tele tele;
 	pthread_t rpt_call_thread,rpt_thread;
 	time_t rem_dtmf_time,dtmf_time_rem;
-	int tailtimer,totimer,idtimer,txconf,conf,callmode,cidx,scantimer;
+	int tailtimer,totimer,idtimer,txconf,conf,callmode,cidx,scantimer,tmsgtimer;
 	int mustid;
 	int politeid;
 	int dtmfidx,rem_dtmfidx;
@@ -387,6 +393,11 @@
 	int longestfunc;
 	int longestnode;
 	int threadrestarts;		
+	int tailmessagetime;
+	int tailsquashedtime;
+	char *tailmessages[500];
+	int tailmessagemax;
+	int tailmessagen;
 	time_t disgorgetime;
 	time_t lastthreadrestarttime;
 	char	nobusyout;
@@ -459,6 +470,44 @@
 	{"remote", function_remote}
 } ;
 	
+static int finddelim(char *str,char *strp[])
+{
+int     i,inquo;
+
+        inquo = 0;
+        i = 0;
+        strp[i++] = str;
+        if (!*str)
+           {
+                strp[0] = 0;
+                return(0);
+           }
+        for(; *str; str++)
+           {
+                if (*str == QUOTECHR)
+                   {
+                        if (inquo)
+                           {
+                                *str = 0;
+                                inquo = 0;
+                           }
+                        else
+                           {
+                                strp[i - 1] = str + 1;
+                                inquo = 1;
+                           }
+		}
+                if ((*str == DELIMCHR) && (!inquo))
+                {
+                        *str = 0;
+                        strp[i++] = str + 1;
+                }
+           }
+        strp[i] = 0;
+        return(i);
+
+}
+
 static int myatoi(char *str)
 {
 int	ret;
@@ -1006,8 +1055,9 @@
 	ci.chan = 0;
 	/* If there's an ID queued, only connect the ID audio to the local tx conference so 
 		linked systems can't hear it */
-	ci.confno = (((mytele->mode == ID) || (mytele->mode == IDTALKOVER) || (mytele->mode == UNKEY)) ?
-		 myrpt->txconf : myrpt->conf);
+	ci.confno = (((mytele->mode == ID) || (mytele->mode == IDTALKOVER) || (mytele->mode == UNKEY) || 
+		(mytele->mode == TAILMSG)) ?
+		 	myrpt->txconf : myrpt->conf);
 	ci.confmode = ZT_CONF_CONFANN;
 	/* first put the channel on the conference in announce mode */
 	if (ioctl(mychannel->fds[0],ZT_SETCONF,&ci) == -1)
@@ -1023,15 +1073,18 @@
 	ast_stopstream(mychannel);
 	switch(mytele->mode)
 	{
+
 	    case ID:
 	    case ID1:
 		/* wait a bit */
 		wait_interval(myrpt, (mytele->mode == ID) ? DLY_ID : DLY_TELEM,mychannel);
 		res = telem_any(mychannel, ident); 
-		imdone=1;
-	
+		imdone=1;	
 		break;
 		
+	    case TAILMSG:
+		res = ast_streamfile(mychannel, myrpt->tailmessages[myrpt->tailmessagen], mychannel->language); 
+		break;
 		
 	    case IDTALKOVER:
 	    	p = ast_variable_retrieve(cfg, nodename, "idtalkover");
@@ -1482,6 +1535,18 @@
 	}
 	ast_stopstream(mychannel);
 	ast_mutex_lock(&myrpt->lock);
+	if (mytele->mode == TAILMSG)
+	{
+		if (!res)
+		{
+			myrpt->tailmessagen++;
+			if(myrpt->tailmessagen >= myrpt->tailmessagemax) myrpt->tailmessagen = 0;
+		}
+		else
+		{
+			myrpt->tmsgtimer = myrpt->tailsquashedtime;
+		}
+	}
 	remque((struct qelem *)mytele);
 	ast_mutex_unlock(&myrpt->lock);
 	free(mytele);		
@@ -2823,7 +2888,7 @@
 	}
 }
 
-static int serial_remote_io(struct rpt *myrpt, char *txbuf, int txbytes, char *rxbuf,
+static int serial_remote_io(struct rpt *myrpt, unsigned char *txbuf, int txbytes, char *rxbuf,
         int rxmaxbytes, int asciiflag)
 {
 	int i;
@@ -2855,7 +2920,8 @@
 
 static int setrbi(struct rpt *myrpt)
 {
-char tmp[MAXREMSTR] = "",rbicmd[5],*s;
+char tmp[MAXREMSTR] = "",*s;
+unsigned char rbicmd[5];
 int	band,txoffset = 0,txpower = 0,txpl;
 
 	/* must be a remote system */
@@ -4528,7 +4594,7 @@
 {
 struct	rpt *myrpt = (struct rpt *)this;
 char *tele,*idtalkover;
-int ms = MSWAIT,lasttx=0,val,remrx=0,identqueued,nonidentqueued,res;
+int ms = MSWAIT,i,lasttx=0,val,remrx=0,identqueued,nonidentqueued,res, tailmessagequeued;
 struct ast_channel *who;
 ZT_CONFINFO ci;  /* conference info */
 time_t	dtmf_time,t;
@@ -4676,7 +4742,8 @@
 	/* make a conference for the pseudo */
 	ci.chan = 0;
 	ci.confno = -1; /* make a new conf */
-	ci.confmode = ZT_CONF_CONFANNMON; 
+	ci.confmode = (myrpt->duplex == 2) ? ZT_CONF_CONFANNMON :
+		(ZT_CONF_CONF | ZT_CONF_LISTENER | ZT_CONF_TALKER);

[... 7219 lines stripped ...]


More information about the asterisk-commits mailing list