[asterisk-commits] branch mogorman/asterisk-xmpp r20103 - in
/team/mogorman/asterisk-xmpp: ./ ap...
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Fri Apr 14 12:12:21 MST 2006
Author: mogorman
Date: Fri Apr 14 14:12:10 2006
New Revision: 20103
URL: http://svn.digium.com/view/asterisk?rev=20103&view=rev
Log:
Merged revisions 20003,20035-20036,20038,20075-20076 via svnmerge from
https://svn.digium.com/svn/asterisk/trunk
................
r20003 | rizzo | 2006-04-14 09:08:19 -0500 (Fri, 14 Apr 2006) | 23 lines
This rather large commit changes the way modules are loaded.
As partly documented in loader.c and include/asterisk/module.h,
modules are now expected to return all of their methods and flags
into a structure 'mod_data', and are normally loaded with RTLD_NOW
| RTLD_LOCAL, so symbols are resolved immediately and conflicts
should be less likely. Only in a small number of cases (res_*,
typically) modules are loaded RTLD_GLOBAL, so they can export
symbols.
The core of the change is only the two files loader.c and
include/asterisk/module.h, all the rest is simply adaptation of the
existing modules to the new API, a rather mechanical (but believe
me, time and finger-consuming!) process whose detail you can figure
out by svn diff'ing any single module.
Expect some minor compilation issue after this change, please
report it on mantis http://bugs.digium.com/view.php?id=6968
so we collect all the feedback in one place.
I am just sorry that this change missed SVN version number 20000!
................
r20035 | kpfleming | 2006-04-14 12:01:07 -0500 (Fri, 14 Apr 2006) | 10 lines
Merged revisions 20034 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r20034 | kpfleming | 2006-04-14 12:00:32 -0500 (Fri, 14 Apr 2006) | 2 lines
update text to match actual prompts being distributed (thanks to Kinsey in the support department for reviewing all the prompts!)
........
................
r20036 | rizzo | 2006-04-14 12:19:57 -0500 (Fri, 14 Apr 2006) | 3 lines
fix a mostly harmless error introduced by svn merge.
................
r20038 | kpfleming | 2006-04-14 12:25:31 -0500 (Fri, 14 Apr 2006) | 10 lines
Merged revisions 20037 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r20037 | kpfleming | 2006-04-14 12:21:09 -0500 (Fri, 14 Apr 2006) | 2 lines
uncomment files that actually do exist (oops)
........
................
r20075 | tilghman | 2006-04-14 13:44:24 -0500 (Fri, 14 Apr 2006) | 2 lines
Compatibility fixes for loader changes
................
r20076 | rizzo | 2006-04-14 13:45:08 -0500 (Fri, 14 Apr 2006) | 3 lines
fix another svn merge bug
................
Modified:
team/mogorman/asterisk-xmpp/ (props changed)
team/mogorman/asterisk-xmpp/apps/app_adsiprog.c
team/mogorman/asterisk-xmpp/apps/app_alarmreceiver.c
team/mogorman/asterisk-xmpp/apps/app_amd.c
team/mogorman/asterisk-xmpp/apps/app_authenticate.c
team/mogorman/asterisk-xmpp/apps/app_cdr.c
team/mogorman/asterisk-xmpp/apps/app_chanisavail.c
team/mogorman/asterisk-xmpp/apps/app_channelredirect.c
team/mogorman/asterisk-xmpp/apps/app_chanspy.c
team/mogorman/asterisk-xmpp/apps/app_controlplayback.c
team/mogorman/asterisk-xmpp/apps/app_db.c
team/mogorman/asterisk-xmpp/apps/app_dial.c
team/mogorman/asterisk-xmpp/apps/app_dictate.c
team/mogorman/asterisk-xmpp/apps/app_directed_pickup.c
team/mogorman/asterisk-xmpp/apps/app_directory.c
team/mogorman/asterisk-xmpp/apps/app_disa.c
team/mogorman/asterisk-xmpp/apps/app_dumpchan.c
team/mogorman/asterisk-xmpp/apps/app_echo.c
team/mogorman/asterisk-xmpp/apps/app_exec.c
team/mogorman/asterisk-xmpp/apps/app_externalivr.c
team/mogorman/asterisk-xmpp/apps/app_festival.c
team/mogorman/asterisk-xmpp/apps/app_flash.c
team/mogorman/asterisk-xmpp/apps/app_forkcdr.c
team/mogorman/asterisk-xmpp/apps/app_getcpeid.c
team/mogorman/asterisk-xmpp/apps/app_hasnewvoicemail.c
team/mogorman/asterisk-xmpp/apps/app_ices.c
team/mogorman/asterisk-xmpp/apps/app_image.c
team/mogorman/asterisk-xmpp/apps/app_ivrdemo.c
team/mogorman/asterisk-xmpp/apps/app_lookupblacklist.c
team/mogorman/asterisk-xmpp/apps/app_lookupcidname.c
team/mogorman/asterisk-xmpp/apps/app_macro.c
team/mogorman/asterisk-xmpp/apps/app_meetme.c
team/mogorman/asterisk-xmpp/apps/app_milliwatt.c
team/mogorman/asterisk-xmpp/apps/app_mixmonitor.c
team/mogorman/asterisk-xmpp/apps/app_morsecode.c
team/mogorman/asterisk-xmpp/apps/app_mp3.c
team/mogorman/asterisk-xmpp/apps/app_nbscat.c
team/mogorman/asterisk-xmpp/apps/app_osplookup.c
team/mogorman/asterisk-xmpp/apps/app_page.c
team/mogorman/asterisk-xmpp/apps/app_parkandannounce.c
team/mogorman/asterisk-xmpp/apps/app_playback.c
team/mogorman/asterisk-xmpp/apps/app_privacy.c
team/mogorman/asterisk-xmpp/apps/app_queue.c
team/mogorman/asterisk-xmpp/apps/app_random.c
team/mogorman/asterisk-xmpp/apps/app_read.c
team/mogorman/asterisk-xmpp/apps/app_readfile.c
team/mogorman/asterisk-xmpp/apps/app_realtime.c
team/mogorman/asterisk-xmpp/apps/app_record.c
team/mogorman/asterisk-xmpp/apps/app_rpt.c
team/mogorman/asterisk-xmpp/apps/app_sayunixtime.c
team/mogorman/asterisk-xmpp/apps/app_senddtmf.c
team/mogorman/asterisk-xmpp/apps/app_sendtext.c
team/mogorman/asterisk-xmpp/apps/app_setcallerid.c
team/mogorman/asterisk-xmpp/apps/app_setcdruserfield.c
team/mogorman/asterisk-xmpp/apps/app_settransfercapability.c
team/mogorman/asterisk-xmpp/apps/app_skel.c
team/mogorman/asterisk-xmpp/apps/app_sms.c
team/mogorman/asterisk-xmpp/apps/app_softhangup.c
team/mogorman/asterisk-xmpp/apps/app_speech_utils.c
team/mogorman/asterisk-xmpp/apps/app_stack.c
team/mogorman/asterisk-xmpp/apps/app_system.c
team/mogorman/asterisk-xmpp/apps/app_talkdetect.c
team/mogorman/asterisk-xmpp/apps/app_test.c
team/mogorman/asterisk-xmpp/apps/app_transfer.c
team/mogorman/asterisk-xmpp/apps/app_url.c
team/mogorman/asterisk-xmpp/apps/app_userevent.c
team/mogorman/asterisk-xmpp/apps/app_verbose.c
team/mogorman/asterisk-xmpp/apps/app_voicemail.c
team/mogorman/asterisk-xmpp/apps/app_waitforring.c
team/mogorman/asterisk-xmpp/apps/app_waitforsilence.c
team/mogorman/asterisk-xmpp/apps/app_while.c
team/mogorman/asterisk-xmpp/apps/app_zapateller.c
team/mogorman/asterisk-xmpp/apps/app_zapbarge.c
team/mogorman/asterisk-xmpp/apps/app_zapras.c
team/mogorman/asterisk-xmpp/apps/app_zapscan.c
team/mogorman/asterisk-xmpp/asterisk.c
team/mogorman/asterisk-xmpp/cdr.c
team/mogorman/asterisk-xmpp/cdr/cdr_csv.c
team/mogorman/asterisk-xmpp/cdr/cdr_custom.c
team/mogorman/asterisk-xmpp/cdr/cdr_manager.c
team/mogorman/asterisk-xmpp/cdr/cdr_odbc.c
team/mogorman/asterisk-xmpp/channels/chan_agent.c
team/mogorman/asterisk-xmpp/channels/chan_features.c
team/mogorman/asterisk-xmpp/channels/chan_iax2.c
team/mogorman/asterisk-xmpp/channels/chan_local.c
team/mogorman/asterisk-xmpp/channels/chan_mgcp.c
team/mogorman/asterisk-xmpp/channels/chan_oss.c
team/mogorman/asterisk-xmpp/channels/chan_phone.c
team/mogorman/asterisk-xmpp/channels/chan_sip.c
team/mogorman/asterisk-xmpp/channels/chan_skinny.c
team/mogorman/asterisk-xmpp/channels/chan_zap.c
team/mogorman/asterisk-xmpp/cli.c
team/mogorman/asterisk-xmpp/codecs/codec_a_mu.c
team/mogorman/asterisk-xmpp/codecs/codec_adpcm.c
team/mogorman/asterisk-xmpp/codecs/codec_alaw.c
team/mogorman/asterisk-xmpp/codecs/codec_g723_1.c
team/mogorman/asterisk-xmpp/codecs/codec_g726.c
team/mogorman/asterisk-xmpp/codecs/codec_gsm.c
team/mogorman/asterisk-xmpp/codecs/codec_ilbc.c
team/mogorman/asterisk-xmpp/codecs/codec_lpc10.c
team/mogorman/asterisk-xmpp/codecs/codec_speex.c
team/mogorman/asterisk-xmpp/codecs/codec_ulaw.c
team/mogorman/asterisk-xmpp/file.c
team/mogorman/asterisk-xmpp/formats/format_g723.c
team/mogorman/asterisk-xmpp/formats/format_g726.c
team/mogorman/asterisk-xmpp/formats/format_g729.c
team/mogorman/asterisk-xmpp/formats/format_gsm.c
team/mogorman/asterisk-xmpp/formats/format_h263.c
team/mogorman/asterisk-xmpp/formats/format_h264.c
team/mogorman/asterisk-xmpp/formats/format_ilbc.c
team/mogorman/asterisk-xmpp/formats/format_jpeg.c
team/mogorman/asterisk-xmpp/formats/format_ogg_vorbis.c
team/mogorman/asterisk-xmpp/formats/format_pcm.c
team/mogorman/asterisk-xmpp/formats/format_sln.c
team/mogorman/asterisk-xmpp/formats/format_vox.c
team/mogorman/asterisk-xmpp/formats/format_wav.c
team/mogorman/asterisk-xmpp/formats/format_wav_gsm.c
team/mogorman/asterisk-xmpp/funcs/func_base64.c
team/mogorman/asterisk-xmpp/funcs/func_callerid.c
team/mogorman/asterisk-xmpp/funcs/func_cdr.c
team/mogorman/asterisk-xmpp/funcs/func_channel.c
team/mogorman/asterisk-xmpp/funcs/func_curl.c
team/mogorman/asterisk-xmpp/funcs/func_cut.c
team/mogorman/asterisk-xmpp/funcs/func_db.c
team/mogorman/asterisk-xmpp/funcs/func_enum.c
team/mogorman/asterisk-xmpp/funcs/func_env.c
team/mogorman/asterisk-xmpp/funcs/func_groupcount.c
team/mogorman/asterisk-xmpp/funcs/func_language.c
team/mogorman/asterisk-xmpp/funcs/func_logic.c
team/mogorman/asterisk-xmpp/funcs/func_math.c
team/mogorman/asterisk-xmpp/funcs/func_md5.c
team/mogorman/asterisk-xmpp/funcs/func_moh.c
team/mogorman/asterisk-xmpp/funcs/func_odbc.c
team/mogorman/asterisk-xmpp/funcs/func_rand.c
team/mogorman/asterisk-xmpp/funcs/func_sha1.c
team/mogorman/asterisk-xmpp/funcs/func_strings.c
team/mogorman/asterisk-xmpp/funcs/func_timeout.c
team/mogorman/asterisk-xmpp/funcs/func_uri.c
team/mogorman/asterisk-xmpp/include/asterisk.h
team/mogorman/asterisk-xmpp/include/asterisk/file.h
team/mogorman/asterisk-xmpp/include/asterisk/module.h
team/mogorman/asterisk-xmpp/include/asterisk/translate.h
team/mogorman/asterisk-xmpp/loader.c
team/mogorman/asterisk-xmpp/pbx/pbx_ael.c
team/mogorman/asterisk-xmpp/pbx/pbx_config.c
team/mogorman/asterisk-xmpp/pbx/pbx_dundi.c
team/mogorman/asterisk-xmpp/pbx/pbx_loopback.c
team/mogorman/asterisk-xmpp/pbx/pbx_realtime.c
team/mogorman/asterisk-xmpp/pbx/pbx_spool.c
team/mogorman/asterisk-xmpp/res/res_adsi.c
team/mogorman/asterisk-xmpp/res/res_agi.c
team/mogorman/asterisk-xmpp/res/res_clioriginate.c
team/mogorman/asterisk-xmpp/res/res_config_odbc.c
team/mogorman/asterisk-xmpp/res/res_config_pgsql.c
team/mogorman/asterisk-xmpp/res/res_convert.c
team/mogorman/asterisk-xmpp/res/res_crypto.c
team/mogorman/asterisk-xmpp/res/res_features.c
team/mogorman/asterisk-xmpp/res/res_indications.c
team/mogorman/asterisk-xmpp/res/res_monitor.c
team/mogorman/asterisk-xmpp/res/res_musiconhold.c
team/mogorman/asterisk-xmpp/res/res_odbc.c
team/mogorman/asterisk-xmpp/res/res_smdi.c
team/mogorman/asterisk-xmpp/res/res_speech.c
team/mogorman/asterisk-xmpp/sounds.txt
team/mogorman/asterisk-xmpp/translate.c
Propchange: team/mogorman/asterisk-xmpp/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.
Propchange: team/mogorman/asterisk-xmpp/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Fri Apr 14 14:12:10 2006
@@ -1,1 +1,1 @@
-/trunk:1-19979
+/trunk:1-20076
Modified: team/mogorman/asterisk-xmpp/apps/app_adsiprog.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_adsiprog.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_adsiprog.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_adsiprog.c Fri Apr 14 14:12:10 2006
@@ -58,8 +58,6 @@
static char *descrip =
" ADSIProg(script): This application programs an ADSI Phone with the given\n"
"script. If nothing is specified, the default script (asterisk.adsi) is used.\n";
-
-LOCAL_USER_DECL;
struct adsi_event {
int id;
@@ -1568,35 +1566,32 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
+
+ STANDARD_HANGUP_LOCALUSERS;
res = ast_unregister_application(app);
- STANDARD_HANGUP_LOCALUSERS;
return res;
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
return ast_register_application(app, adsi_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Asterisk ADSI Programming Application";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_alarmreceiver.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_alarmreceiver.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_alarmreceiver.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_alarmreceiver.c Fri Apr 14 14:12:10 2006
@@ -96,8 +96,6 @@
/* Misc variables */
static char event_file[14] = "/event-XXXXXX";
-
-LOCAL_USER_DECL;
/*
* Attempt to access a database variable and increment it,
@@ -818,7 +816,7 @@
*/
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -829,25 +827,21 @@
return res;
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
load_config();
return ast_register_application(app, alarmreceiver_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Alarm Receiver for Asterisk";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_amd.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_amd.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_amd.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_amd.c Fri Apr 14 14:12:10 2006
@@ -72,9 +72,6 @@
" MAXWORDS-<%d wordsCount>-<%d maximumNumberOfWords>\n"
" LONGGREETING-<%d voiceDuration>-<%d greeting>\n";
-
-LOCAL_USER_DECL;
-
#define STATE_IN_WORD 1
#define STATE_IN_SILENCE 2
@@ -392,38 +389,33 @@
return;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
STANDARD_HANGUP_LOCALUSERS;
return ast_unregister_application(app);
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
load_config();
return ast_register_application(app, amd_exec, synopsis, descrip);
}
-int reload(void)
+static int reload(void *mod)
{
load_config();
return 0;
}
-const char *description(void)
+static const char *description(void)
{
return "Answering Machine Detection Application";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+STD_MOD(MOD_1, reload, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_authenticate.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_authenticate.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_authenticate.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_authenticate.c Fri Apr 14 14:12:10 2006
@@ -90,8 +90,6 @@
" press the '#' key).\n"
" Defaults to 0 - no limit - wait for the user press the '#' key.\n"
;
-
-LOCAL_USER_DECL;
static int auth_exec(struct ast_channel *chan, void *data)
{
@@ -235,35 +233,31 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
+ STANDARD_HANGUP_LOCALUSERS;
+
res = ast_unregister_application(app);
- STANDARD_HANGUP_LOCALUSERS;
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, auth_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Authentication Application";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_cdr.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_cdr.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_cdr.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_cdr.c Fri Apr 14 14:12:10 2006
@@ -27,8 +27,6 @@
#include <sys/types.h>
#include <stdlib.h>
-
-#define STATIC_MODULE
#include "asterisk.h"
@@ -63,7 +61,7 @@
return 0;
}
-STATIC_MODULE int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -74,24 +72,17 @@
return res;
}
-STATIC_MODULE int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(nocdr_app, nocdr_exec, nocdr_synopsis, nocdr_descrip);
}
-STATIC_MODULE const char *description(void)
+static const char *description(void)
{
return "Tell Asterisk to not maintain a CDR for the current call";
}
-STATIC_MODULE int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-STATIC_MODULE const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
Modified: team/mogorman/asterisk-xmpp/apps/app_chanisavail.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_chanisavail.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_chanisavail.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_chanisavail.c Fri Apr 14 14:12:10 2006
@@ -155,7 +155,7 @@
return 0;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res = 0;
@@ -166,24 +166,20 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
+ __mod_desc = mod;
return ast_register_application(app, chanavail_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Check channel availability";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_channelredirect.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_channelredirect.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_channelredirect.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_channelredirect.c Fri Apr 14 14:12:10 2006
@@ -120,7 +120,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -131,26 +131,20 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
+ __mod_desc = mod;
return ast_register_application(app, asyncgoto_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Channel Redirect";
}
-int usecount(void)
-{
- int res;
-
- STANDARD_USECOUNT(res);
-
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_chanspy.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_chanspy.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_chanspy.c Fri Apr 14 14:12:10 2006
@@ -554,7 +554,7 @@
ALL_DONE(u, res);
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -565,24 +565,20 @@
return res;
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
return ast_register_application(app, chanspy_exec, synopsis, desc);
}
-const char *description(void)
+static const char *description(void)
{
return (char *) synopsis;
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_controlplayback.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_controlplayback.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_controlplayback.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_controlplayback.c Fri Apr 14 14:12:10 2006
@@ -154,36 +154,26 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
-
res = ast_unregister_application(app);
-
- STANDARD_HANGUP_LOCALUSERS;
-
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, controlplayback_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return "Control Playback Application";
}
-int usecount(void)
-{
- int res;
-
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_db.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_db.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_db.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_db.c Fri Apr 14 14:12:10 2006
@@ -143,41 +143,35 @@
return 0;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int retval;
retval = ast_unregister_application(dt_app);
retval |= ast_unregister_application(d_app);
- STANDARD_HANGUP_LOCALUSERS;
-
return retval;
}
-int load_module(void)
+static int load_module(void *mod)
{
int retval;
+ __mod_desc = mod;
retval = ast_register_application(d_app, del_exec, d_synopsis, d_descrip);
retval |= ast_register_application(dt_app, deltree_exec, dt_synopsis, dt_descrip);
return retval;
}
-const char *description(void)
+static const char *description(void)
{
return "Database Access Functions";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_dial.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_dial.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_dial.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_dial.c Fri Apr 14 14:12:10 2006
@@ -35,7 +35,6 @@
#include <sys/signal.h>
#include <netinet/in.h>
-#define STATIC_MODULE
#include "asterisk.h"
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
@@ -1729,7 +1728,7 @@
}
-STATIC_MODULE int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -1741,30 +1740,24 @@
return res;
}
-STATIC_MODULE int load_module(void)
+static int load_module(void *mod)
{
int res;
+ __mod_desc = mod;
res = ast_register_application(app, dial_exec, synopsis, descrip);
res |= ast_register_application(rapp, retrydial_exec, rsynopsis, rdescrip);
return res;
}
-STATIC_MODULE const char *description(void)
+static const char *description(void)
{
return "Dialing Application";
}
-STATIC_MODULE int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-STATIC_MODULE const char *key(void)
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
Modified: team/mogorman/asterisk-xmpp/apps/app_dictate.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_dictate.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_dictate.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_dictate.c Fri Apr 14 14:12:10 2006
@@ -46,7 +46,6 @@
#include "asterisk/lock.h"
#include "asterisk/app.h"
-static char *tdesc = "Virtual Dictation Machine";
static char *app = "Dictate";
static char *synopsis = "Virtual Dictation Machine";
static char *desc = " Dictate([<base_dir>[|<filename>]])\n"
@@ -336,36 +335,27 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
-
res = ast_unregister_application(app);
-
- STANDARD_HANGUP_LOCALUSERS;
-
return res;
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
return ast_register_application(app, dictate_exec, synopsis, desc);
}
-const char *description(void)
-{
- return tdesc;
-}
-
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *description(void)
+{
+ return "Virtual Dictation Machine";
+}
+
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_directed_pickup.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_directed_pickup.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_directed_pickup.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_directed_pickup.c Fri Apr 14 14:12:10 2006
@@ -42,7 +42,6 @@
#include "asterisk/lock.h"
#include "asterisk/app.h"
-static const char *tdesc = "Directed Call Pickup Application";
static const char *app = "Pickup";
static const char *synopsis = "Directed Call Pickup";
static const char *descrip =
@@ -134,37 +133,29 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
res = ast_unregister_application(app);
- STANDARD_HANGUP_LOCALUSERS;
-
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
+ __mod_desc = mod;
return ast_register_application(app, pickup_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
- return (char *) tdesc;
+ return "Directed Call Pickup Application";
}
-int usecount(void)
-{
- int res;
-
- STANDARD_USECOUNT(res);
-
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD(MOD_1, NULL, NULL, NULL);
Modified: team/mogorman/asterisk-xmpp/apps/app_directory.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_directory.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_directory.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_directory.c Fri Apr 14 14:12:10 2006
@@ -45,7 +45,6 @@
#include "asterisk/utils.h"
#include "asterisk/app.h"
-static char *tdesc = "Extension Directory";
static char *app = "Directory";
static char *synopsis = "Provide directory of voicemail extensions";
@@ -517,35 +516,27 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
-
res = ast_unregister_application(app);
-
- STANDARD_HANGUP_LOCALUSERS;
-
return res;
}
-int load_module(void)
-{
+static int load_module(void *mod)
+{
+ __mod_desc = mod;
return ast_register_application(app, directory_exec, synopsis, descrip);
}
-const char *description(void)
-{
- return tdesc;
-}
-
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *description(void)
+{
+ return "Extension Directory";
+}
+
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_disa.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_disa.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_disa.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_disa.c Fri Apr 14 14:12:10 2006
@@ -48,8 +48,6 @@
#include "asterisk/ulaw.h"
#include "asterisk/callerid.h"
#include "asterisk/stringfields.h"
-
-static char *tdesc = "DISA (Direct Inward System Access) Application";
static char *app = "DISA";
@@ -376,7 +374,7 @@
return -1;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -387,24 +385,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, disa_exec, synopsis, descrip);
}
-const char *description(void)
-{
- return tdesc;
-}
-
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key(void)
+static const char *description(void)
+{
+ return "DISA (Direct Inward System Access) Application";
+}
+
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_dumpchan.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_dumpchan.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_dumpchan.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_dumpchan.c Fri Apr 14 14:12:10 2006
@@ -46,7 +46,6 @@
#include "asterisk/lock.h"
#include "asterisk/utils.h"
-static char *tdesc = "Dump Info About The Calling Channel";
static char *app = "DumpChan";
static char *synopsis = "Dump Info About The Calling Channel";
static char *desc =
@@ -157,7 +156,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -168,25 +167,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, dumpchan_exec, synopsis, desc);
}
-const char *description(void)
+static const char *description(void)
{
- return tdesc;
+ return "Dump Info About The Calling Channel";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_echo.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_echo.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_echo.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_echo.c Fri Apr 14 14:12:10 2006
@@ -95,7 +95,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -106,24 +106,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, echo_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
return tdesc;
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_exec.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_exec.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_exec.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_exec.c Fri Apr 14 14:12:10 2006
@@ -160,7 +160,7 @@
return 0;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -172,26 +172,21 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
int res = ast_register_application(app_exec, exec_exec, exec_synopsis, exec_descrip);
res |= ast_register_application(app_tryexec, tryexec_exec, tryexec_synopsis, tryexec_descrip);
return res;
}
-const char *description(void)
+static const char *description(void)
{
return tdesc;
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_externalivr.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_externalivr.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_externalivr.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_externalivr.c Fri Apr 14 14:12:10 2006
@@ -51,7 +51,6 @@
#include "asterisk/app.h"
#include "asterisk/utils.h"
-static const char *tdesc = "External IVR Interface Application";
static const char *app = "ExternalIVR";
@@ -551,7 +550,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -562,26 +561,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, app_exec, synopsis, descrip);
}
-const char *description(void)
-{
- return (char *) tdesc;
-}
-
-int usecount(void)
-{
- int res;
-
- STANDARD_USECOUNT(res);
-
- return res;
-}
-
-const char *key()
+static const char *description(void)
+{
+ return "External IVR Interface Application";
+}
+
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_festival.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_festival.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_festival.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_festival.c Fri Apr 14 14:12:10 2006
@@ -57,8 +57,6 @@
#include "asterisk/lock.h"
#define FESTIVAL_CONFIG "festival.conf"
-
-static char *tdesc = "Simple Festival Interface";
static char *app = "Festival";
@@ -501,7 +499,7 @@
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -512,25 +510,20 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
-
return ast_register_application(app, festival_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
- return tdesc;
-}
-
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+ return "Simple Festival Interface";
+
+}
+
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_flash.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_flash.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_flash.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_flash.c Fri Apr 14 14:12:10 2006
@@ -49,8 +49,6 @@
#include "asterisk/translate.h"
#include "asterisk/image.h"
#include "asterisk/options.h"
-
-static char *tdesc = "Flash zap trunk application";
static char *app = "Flash";
@@ -107,7 +105,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -118,24 +116,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, flash_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
- return tdesc;
+ return "Flash zap trunk application";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_forkcdr.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_forkcdr.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_forkcdr.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_forkcdr.c Fri Apr 14 14:12:10 2006
@@ -42,7 +42,6 @@
#include "asterisk/cdr.h"
#include "asterisk/module.h"
-static char *tdesc = "Fork The CDR into 2 separate entities.";
static char *app = "ForkCDR";
static char *synopsis =
"Forks the Call Data Record";
@@ -98,7 +97,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -109,24 +108,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, forkcdr_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
- return tdesc;
+ return "Fork The CDR into 2 separate entities.";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_getcpeid.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_getcpeid.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_getcpeid.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_getcpeid.c Fri Apr 14 14:12:10 2006
@@ -42,8 +42,6 @@
#include "asterisk/module.h"
#include "asterisk/adsi.h"
#include "asterisk/options.h"
-
-static char *tdesc = "Get ADSI CPE ID";
static char *app = "GetCPEID";
@@ -133,7 +131,7 @@
return res;
}
-int unload_module(void)
+static int unload_module(void *mod)
{
int res;
@@ -144,24 +142,19 @@
return res;
}
-int load_module(void)
+static int load_module(void *mod)
{
return ast_register_application(app, cpeid_exec, synopsis, descrip);
}
-const char *description(void)
+static const char *description(void)
{
- return tdesc;
+ return "Get ADSI CPE ID";
}
-int usecount(void)
-{
- int res;
- STANDARD_USECOUNT(res);
- return res;
-}
-
-const char *key()
+static const char *key(void)
{
return ASTERISK_GPL_KEY;
}
+
+STD_MOD1;
Modified: team/mogorman/asterisk-xmpp/apps/app_hasnewvoicemail.c
URL: http://svn.digium.com/view/asterisk/team/mogorman/asterisk-xmpp/apps/app_hasnewvoicemail.c?rev=20103&r1=20102&r2=20103&view=diff
==============================================================================
--- team/mogorman/asterisk-xmpp/apps/app_hasnewvoicemail.c (original)
+++ team/mogorman/asterisk-xmpp/apps/app_hasnewvoicemail.c Fri Apr 14 14:12:10 2006
@@ -53,7 +53,6 @@
#include "asterisk/app.h"
#include "asterisk/options.h"
[... 8739 lines stripped ...]
More information about the asterisk-commits
mailing list