Commit Graph

54 Commits

Author SHA1 Message Date
Anthony Minessale dc96942b88 update
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6455 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-11-30 23:45:27 +00:00
Michael Jerris 622a2733dc use more correct const char * for things that should not be modified. This should also fix the switch_cpp.cpp changes from MODAPP-44. More patches to follow up on this for a few more modules that will likely break with this commit.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6120 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-11-01 11:28:26 +00:00
Anthony Minessale 0300e8e64a 7 not 4
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6114 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-10-31 22:29:15 +00:00
Anthony Minessale b099f96e4e format
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5925 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-10-17 14:59:17 +00:00
Anthony Minessale ffb989e435 tear the hell out of everything and rip it up into itsy bitsy pieces and put it all back together
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5765 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-09-29 01:06:08 +00:00
Michael Jerris f1222ba2fd fix for FSCORE-40
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5566 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-08-03 21:29:01 +00:00
Anthony Minessale 25057d40ac fix up some event issues
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5541 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-07-24 21:26:04 +00:00
Anthony Minessale a039d870c3 Add events around all application execution:
fire SWITCH_EVEHT_CHANNEL_EXECUTE
<execute app>
fire SWITCH_EVEHT_CHANNEL_EXECUTE_COMPLETE

This can be used in async socket connections to tell
when a queued application has finished executing.



Add the "event" application to the dialplan:

<action application="event" data="header1=val1,header2=val2"/>

Events fired from this applcation will always have the type SWITCH_EVENT_CHANNEL_APPLICATION.

You can add up to 25 headers of your own to the event via the application arguements.





git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5448 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-23 05:41:07 +00:00
Michael Jerris ae02cbef83 add more modules to new mod loader macros/api.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5404 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-20 07:53:33 +00:00
Anthony Minessale 95f007586f stage 1 of wrecking ball (duck!)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5347 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-13 20:40:06 +00:00
Michael Jerris b67f9c5b2a move some modules to use the new module interface macros.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5343 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-13 17:06:10 +00:00
Anthony Minessale efca0c8087 hack up the core with a butcher knife
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5314 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-12 21:00:26 +00:00
Anthony Minessale 91cb42b7ea fix accidental missing event enum name
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5291 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-06-08 15:17:43 +00:00
Anthony Minessale debdfb1aab indent
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4798 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-03-30 00:13:31 +00:00
Anthony Minessale 3a54126261 spring cleaning
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4795 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-03-29 22:31:56 +00:00
Michael Jerris ce81898c5d null format string error
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4651 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-03-19 00:41:23 +00:00
Michael Jerris 42e78242a3 add wrapper code to fully encapsulate apr, apr-utils, pcre, and sqlite. fully use switch_ namespace in modules, create our own format and type defines. follow up commit for unix autotools coming soon after this. PLEASE NOTE: you will NEED to do a make megaclean and run configure again after this update (and the following commit) or it will not build.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4494 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-03-09 20:44:13 +00:00
Michael Jerris 3e3760a996 add flags to the application interface for marking if apps support no media mode. FSCORE-7
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4400 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-26 21:38:10 +00:00
Anthony Minessale a644b549c5 remove redundant strlen
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4357 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-23 16:43:07 +00:00
Michael Jerris db797b8130 match new prototype for switch_ivr_park
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4303 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-16 23:12:20 +00:00
Michael Jerris 11a8218db0 potential format string exploits (warning: format not a string literal and no format arguments)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4254 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-14 03:45:10 +00:00
Michael Jerris 07d6f12018 use "%s" format specifier for uses of switch_event_add_header that just pass a string to avoid potential issues/exploits"
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4226 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-13 04:43:49 +00:00
Michael Jerris f359f847f7 fix magic emacs and vi formatting comments in the bottom of our source files to use tabs instead of spaces
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4176 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-09 02:36:03 +00:00
Anthony Minessale 5bb82ebbf8 fix event_socket
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4141 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-02-06 21:42:22 +00:00
Anthony Minessale 151e400ebe let bgapi choose your own id
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4014 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-01-21 19:36:55 +00:00
Anthony Minessale 09384634cc add getvar
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3931 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-01-09 00:39:11 +00:00
Michael Jerris e614e06545 datatype to match usage.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3920 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-01-06 20:24:37 +00:00
Anthony Minessale 9d1e2e9167 don't call us we'll call you
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3917 d0543943-73ff-0310-b7d9-9358b9ac24b2
2007-01-06 17:06:18 +00:00
Michael Jerris 47343dcb87 api commands should not return false unless there is a fatal error warnings about no such command etc still considered sucess cos it has io
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3796 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-12-22 18:39:36 +00:00
Michael Jerris 44649c70b4 Add magic comments for emacs and vi in source and header files to properly format and display tabs vs. spaces in those editors:
/* For Emacs:
 * Local Variables:
 * mode:c
 * indent-tabs-mode:nil
 * tab-width:4
 * c-basic-offset:4
 * End:
 * For VIM:
 * vim:set softtabstop=4 shiftwidth=4 tabstop=4 expandtab:
 */


git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3462 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-11-27 22:30:48 +00:00
Anthony Minessale 68bab16e37 make event_serialize dynamic
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3314 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-11-11 19:32:45 +00:00
Anthony Minessale 44fc26f7d4 Finalization of speech detect interface and API
This changes the core to have the necessary tools to create
a speech detection interface.

It also changes the code in javascript (mod_spidermonkey)
there are a few api changes in how it handles callbacks

It also adds grammars as a system dir to store asr grammars




git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3291 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-11-09 05:39:04 +00:00
Anthony Minessale 2d3ab6b5d8 let you pick event type
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3169 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-10-23 22:32:50 +00:00
Anthony Minessale 7e61bcf9bb fix
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3133 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-10-21 03:19:48 +00:00
Anthony Minessale ce984a90fe present from tony
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3111 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-10-19 19:09:51 +00:00
Anthony Minessale 858cc7fa19 present from pdt
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3110 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-10-19 18:52:46 +00:00
Anthony Minessale 4c386b1959 dont write nulls in event_socket
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3045 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-10-13 14:32:38 +00:00
Michael Jerris 7805761afd types change for msvc build.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2853 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-09-28 01:39:42 +00:00
Anthony Minessale 18a7339d8a remove potential buffer overrun
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2833 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-09-25 20:04:40 +00:00
Anthony Minessale 464eada653 add sendevent command to event_socket
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2780 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-09-22 13:52:36 +00:00
Anthony Minessale fadbb9d401 add nixevent command to allow 'events all' followed by 'nixevent <some_event>' to do all but 1 type scenerio (inspired by pdt)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2763 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-09-20 14:57:13 +00:00
Anthony Minessale 80722357a6 Mega Changes
adding mod_park for putting channels in limbo state for remote control.
adding stuff to mod_event_socket to let you do the bgapi <command> <args>
this will let you execute a job in the bg and the result will be sent as an event with an
indicated uuid to match the reply to the command

adding switch_core_port_allocator (to be used soon)
adding "make sure" to do a full rebild of the freeswitch object files

There will be more to this committed as the week progresses

make sure you do a rebuild after this update or you'll be sowwie
./configure && make sure




git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2540 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-09-07 03:58:01 +00:00
Anthony Minessale 15696c8696 add an element
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2442 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-30 04:58:13 +00:00
Anthony Minessale 300737a18a bigger socket bufer
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2437 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-29 23:06:12 +00:00
Anthony Minessale 884cfc4465 fix event_socket bugs
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2430 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-29 20:27:43 +00:00
Anthony Minessale 3b09338cee more socket stuff
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2263 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-11 18:59:25 +00:00
Anthony Minessale 44095d48ef socket tweak
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2260 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-11 18:20:04 +00:00
Anthony Minessale 7ccdd37a71 socket code
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2257 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-11 15:25:49 +00:00
Anthony Minessale 010e85da14 temp fix socket issue on win
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2236 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-08-07 21:16:54 +00:00
Anthony Minessale c4d890e0a4 Modify XML Dialplan
BTW, forget what I said yesterday RE: the strftime app I was at McDonalds, how can I concentrate there eh? 
see below....


The Definitive Guide To XML Dialplan:

The "dialplan" section of the freeswitch.xml meta document may contain several contexts

<?xml version="1.0"?>
<document type="freeswitch/xml">
  <section name="dialplan" description="Regex/XML Dialplan">
    <!-- the default context is a safe start -->
    <context name="default">

    <!-- one or more extension tags -->

    </context>
    
    <!-- more optional contexts -->
  </section>
</document>

The important thing to remember is that the dialplan is parsed once when the call
hits the dialplan parser in the RING state.  With one pass across the XML the result
will be a complete list of instructions installed into the channel based on
 parsed <action> or <anti-action> tags.

Those accustomed to Asterisk may expect the call to follow the dialplan by executing the 
applications as it parses them allowing data obtained from one action to influence the next action.
This not the case with the exception being the %{api func} {api arg} field type where an pluggable api call from
a module may be executed as the parsing occurs but this is meant to be used to draw realtime info such as
date and time or other quickly accessible information and shold *not* be abused.


The anatomy of an <extension> tag.

Legend: 
Text wrapped in [] indicates optional and is not part of the actual code.
a '|' inside [] indicates mutiple possible values and also is not part of the code.
Text wrapped in {} indicates it's a description of the parameter in place of the param itself.

<extension name="{exten_name}" [continue="[true|false]"]> 

continue=true means even if an extension executes to continue
parsing the next extension too

The {exten_name} above may anything but if it's 
an exact match with the destination number the parser will leap to this extension
to begin the searching that does not mean it will execute the extension.

Searching will either begin at the first extension in the context or at the point
the the parser has jumped to in the case described above.

Each condition is parsed in turn first taking the 'field' param.
The parser will apply the perl regular expression to each 'field' param encountered.

If the expression matches, it will parse each existing <action> tag in turn and add 
the data from the <application> tags to the channels todo list.	

If a matched expression contains any data wrapped in () the variables
$1,$2..$N will be valid and expanded in any of 'data' params from the subsequent action tags.

If the expression does NOT match, it will parse each <anti-action> tag in turn and add 
the data from the <application> tags to the channels todo list.
*NOTE* since there was no match the () feature is not availabe in anti-actions

The 'break' param indicates how to behave in relation to matching:
*) 'on-true'  - stop searching conditions after the first successful match.
*) 'on-false' - stop searching after the first unsuccessful match.
*) 'always'   - stop at this conditon regardless of a match or non-match.
*) 'never'    - continue searching regardless of a match or non-match.

<condition field="[{field name}|${variable name}|%{api func} {api arg}]" expression="{expression}" break="[on-true|on-false|always|never]">
  <action application="{app name}" data="{app arg}"/>
  <anti-action application="{app name}" data="{app arg}"/>
</condition>

  <!-- any number of condition tags may follow where the same rules apply -->
</extension>




git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2167 d0543943-73ff-0310-b7d9-9358b9ac24b2
2006-07-26 20:12:49 +00:00