From c90457726966898cee2836e3cc025e890fcc690b Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Sun, 30 Apr 2006 18:24:24 +0000 Subject: [PATCH] C++ says we can't use "interface" as a variable name. git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@1305 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/include/switch_loadable_module.h | 2 +- .../mod_bridgecall/mod_bridgecall.c | 4 +- .../applications/mod_commands/mod_commands.c | 4 +- src/mod/applications/mod_echo/mod_echo.c | 4 +- .../applications/mod_ivrtest/mod_ivrtest.c | 4 +- .../applications/mod_playback/mod_playback.c | 4 +- src/mod/asr_tts/mod_cepstral/mod_cepstral.c | 4 +- src/mod/codecs/mod_g711/mod_g711.c | 4 +- src/mod/codecs/mod_g729/mod_g729.c | 4 +- src/mod/codecs/mod_gsm/mod_gsm.c | 4 +- src/mod/codecs/mod_ilbc/mod_ilbc.c | 4 +- src/mod/codecs/mod_l16/mod_l16.c | 4 +- src/mod/codecs/mod_speex/mod_speex.c | 4 +- .../mod_dialplan_demo/mod_dialplan_demo.c | 4 +- .../mod_dialplan_directory.c | 4 +- src/mod/dialplans/mod_pcre/mod_pcre.c | 4 +- src/mod/directories/mod_ldap/mod_ldap.c | 4 +- .../endpoints/mod_dingaling/mod_dingaling.c | 4 +- src/mod/endpoints/mod_exosip/mod_exosip.c | 4 +- src/mod/endpoints/mod_iax/mod_iax.c | 4 +- .../endpoints/mod_portaudio/mod_portaudio.c | 4 +- src/mod/endpoints/mod_woomera/mod_woomera.c | 4 +- .../mod_event_multicast/mod_event_multicast.c | 4 +- .../mod_event_test/mod_event_test.c | 4 +- .../mod_xmpp_event/mod_xmpp_event.c | 4 +- .../mod_zeroconf/mod_zeroconf.c | 4 +- src/mod/formats/mod_sndfile/mod_sndfile.c | 4 +- src/mod/languages/mod_perl/mod_perl.c | 4 +- .../mod_spidermonkey/mod_spidermonkey.c | 4 +- src/mod/loggers/mod_console/mod_console.c | 4 +- src/mod/timers/mod_softtimer/mod_softtimer.c | 4 +- src/switch_loadable_module.c | 64 +++++++++---------- 32 files changed, 93 insertions(+), 93 deletions(-) diff --git a/src/include/switch_loadable_module.h b/src/include/switch_loadable_module.h index 70141cdab3..8e5c8ca65a 100644 --- a/src/include/switch_loadable_module.h +++ b/src/include/switch_loadable_module.h @@ -216,7 +216,7 @@ SWITCH_DECLARE(switch_status_t) switch_loadable_module_load_module(char *dir, ch \param filename the path to the module's dll or so file \return SWITCH_STATUS_SUCCESS on a successful load */ -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename); +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename); SWITCH_MOD_DECLARE(switch_status_t) switch_module_reload(void); SWITCH_MOD_DECLARE(switch_status_t) switch_module_pause(void); SWITCH_MOD_DECLARE(switch_status_t) switch_module_resume(void); diff --git a/src/mod/applications/mod_bridgecall/mod_bridgecall.c b/src/mod/applications/mod_bridgecall/mod_bridgecall.c index c81d8d61d2..65ea85ede4 100644 --- a/src/mod/applications/mod_bridgecall/mod_bridgecall.c +++ b/src/mod/applications/mod_bridgecall/mod_bridgecall.c @@ -95,11 +95,11 @@ static const switch_loadable_module_interface_t mod_bridgecall_module_interface /*.application_interface */ &bridge_application_interface }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &mod_bridgecall_module_interface; + *module_interface = &mod_bridgecall_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/applications/mod_commands/mod_commands.c b/src/mod/applications/mod_commands/mod_commands.c index 10b480bcae..e93f2768ab 100644 --- a/src/mod/applications/mod_commands/mod_commands.c +++ b/src/mod/applications/mod_commands/mod_commands.c @@ -171,11 +171,11 @@ static const switch_loadable_module_interface_t mod_commands_module_interface = }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &mod_commands_module_interface; + *module_interface = &mod_commands_module_interface; /* indicate that the module should continue to be loaded */ diff --git a/src/mod/applications/mod_echo/mod_echo.c b/src/mod/applications/mod_echo/mod_echo.c index ceb918a25d..dc40bd7e86 100644 --- a/src/mod/applications/mod_echo/mod_echo.c +++ b/src/mod/applications/mod_echo/mod_echo.c @@ -64,10 +64,10 @@ static switch_loadable_module_interface_t echo_module_interface = { /*.directory_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &echo_module_interface; + *module_interface = &echo_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/applications/mod_ivrtest/mod_ivrtest.c b/src/mod/applications/mod_ivrtest/mod_ivrtest.c index 8f9399290b..67b05f596f 100644 --- a/src/mod/applications/mod_ivrtest/mod_ivrtest.c +++ b/src/mod/applications/mod_ivrtest/mod_ivrtest.c @@ -241,11 +241,11 @@ static const switch_loadable_module_interface_t mod_ivrtest_module_interface = { /*.application_interface */ &ivrtest_application_interface }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &mod_ivrtest_module_interface; + *module_interface = &mod_ivrtest_module_interface; /* test global state handlers */ switch_core_add_state_handler(&state_handlers); diff --git a/src/mod/applications/mod_playback/mod_playback.c b/src/mod/applications/mod_playback/mod_playback.c index 7d47d47f16..a7b10376a3 100644 --- a/src/mod/applications/mod_playback/mod_playback.c +++ b/src/mod/applications/mod_playback/mod_playback.c @@ -106,11 +106,11 @@ static const switch_loadable_module_interface_t mod_playback_module_interface = /*.application_interface */ &playback_application_interface }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &mod_playback_module_interface; + *module_interface = &mod_playback_module_interface; /* indicate that the module should continue to be loaded */ diff --git a/src/mod/asr_tts/mod_cepstral/mod_cepstral.c b/src/mod/asr_tts/mod_cepstral/mod_cepstral.c index f8794e4091..0318df4a58 100644 --- a/src/mod/asr_tts/mod_cepstral/mod_cepstral.c +++ b/src/mod/asr_tts/mod_cepstral/mod_cepstral.c @@ -269,7 +269,7 @@ static const switch_loadable_module_interface_t cepstral_module_interface = { /*.directory_interface */ NULL }; -switch_status_t switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +switch_status_t switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* Open the Swift TTS Engine */ @@ -279,7 +279,7 @@ switch_status_t switch_module_load(const switch_loadable_module_interface_t **in } /* connect my internal structure to the blank pointer passed to me */ - *interface = &cepstral_module_interface; + *module_interface = &cepstral_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/codecs/mod_g711/mod_g711.c b/src/mod/codecs/mod_g711/mod_g711.c index bf323b6384..c3fe511693 100644 --- a/src/mod/codecs/mod_g711/mod_g711.c +++ b/src/mod/codecs/mod_g711/mod_g711.c @@ -302,10 +302,10 @@ static switch_loadable_module_interface_t g711_module_interface = { }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &g711_module_interface; + *module_interface = &g711_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/codecs/mod_g729/mod_g729.c b/src/mod/codecs/mod_g729/mod_g729.c index 61cc3a71bc..9f6f72861e 100644 --- a/src/mod/codecs/mod_g729/mod_g729.c +++ b/src/mod/codecs/mod_g729/mod_g729.c @@ -272,12 +272,12 @@ static switch_loadable_module_interface_t g729_module_interface = { -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &g729_module_interface; + *module_interface = &g729_module_interface; /* indicate that the module should continue to be loaded */ diff --git a/src/mod/codecs/mod_gsm/mod_gsm.c b/src/mod/codecs/mod_gsm/mod_gsm.c index 48a4c6d93e..b8bfb7e46d 100644 --- a/src/mod/codecs/mod_gsm/mod_gsm.c +++ b/src/mod/codecs/mod_gsm/mod_gsm.c @@ -162,12 +162,12 @@ static switch_loadable_module_interface_t gsm_module_interface = { /*.codec_interface */ &gsm_codec_interface, /*.application_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &gsm_module_interface; + *module_interface = &gsm_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/codecs/mod_ilbc/mod_ilbc.c b/src/mod/codecs/mod_ilbc/mod_ilbc.c index 6c17a51fa4..282eaae74c 100644 --- a/src/mod/codecs/mod_ilbc/mod_ilbc.c +++ b/src/mod/codecs/mod_ilbc/mod_ilbc.c @@ -274,12 +274,12 @@ static switch_loadable_module_interface_t ilbc_module_interface = { -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &ilbc_module_interface; + *module_interface = &ilbc_module_interface; /* indicate that the module should continue to be loaded */ diff --git a/src/mod/codecs/mod_l16/mod_l16.c b/src/mod/codecs/mod_l16/mod_l16.c index 9f584899fe..ae61ac19f7 100644 --- a/src/mod/codecs/mod_l16/mod_l16.c +++ b/src/mod/codecs/mod_l16/mod_l16.c @@ -196,10 +196,10 @@ static switch_loadable_module_interface_t raw_module_interface = { }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &raw_module_interface; + *module_interface = &raw_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/codecs/mod_speex/mod_speex.c b/src/mod/codecs/mod_speex/mod_speex.c index cbeded78d6..92edd889ab 100644 --- a/src/mod/codecs/mod_speex/mod_speex.c +++ b/src/mod/codecs/mod_speex/mod_speex.c @@ -334,10 +334,10 @@ static switch_loadable_module_interface_t speex_module_interface = { /*.application_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &speex_module_interface; + *module_interface = &speex_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/dialplans/mod_dialplan_demo/mod_dialplan_demo.c b/src/mod/dialplans/mod_dialplan_demo/mod_dialplan_demo.c index ad19834510..0a5f4ebce7 100644 --- a/src/mod/dialplans/mod_dialplan_demo/mod_dialplan_demo.c +++ b/src/mod/dialplans/mod_dialplan_demo/mod_dialplan_demo.c @@ -117,11 +117,11 @@ static const switch_loadable_module_interface_t demo_dialplan_module_interface = /*.application_interface = */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &demo_dialplan_module_interface; + *module_interface = &demo_dialplan_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/dialplans/mod_dialplan_directory/mod_dialplan_directory.c b/src/mod/dialplans/mod_dialplan_directory/mod_dialplan_directory.c index f6ae62956a..c5453d63ef 100644 --- a/src/mod/dialplans/mod_dialplan_directory/mod_dialplan_directory.c +++ b/src/mod/dialplans/mod_dialplan_directory/mod_dialplan_directory.c @@ -168,12 +168,12 @@ static const switch_loadable_module_interface_t directory_dialplan_module_interf /*.application_interface = */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { load_config(); /* connect my internal structure to the blank pointer passed to me */ - *interface = &directory_dialplan_module_interface; + *module_interface = &directory_dialplan_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/dialplans/mod_pcre/mod_pcre.c b/src/mod/dialplans/mod_pcre/mod_pcre.c index ddff119424..a2b349469a 100644 --- a/src/mod/dialplans/mod_pcre/mod_pcre.c +++ b/src/mod/dialplans/mod_pcre/mod_pcre.c @@ -213,11 +213,11 @@ static const switch_loadable_module_interface_t dialplan_module_interface = { /*.application_interface = */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &dialplan_module_interface; + *module_interface = &dialplan_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/directories/mod_ldap/mod_ldap.c b/src/mod/directories/mod_ldap/mod_ldap.c index 535136bc04..3b6171dcd1 100644 --- a/src/mod/directories/mod_ldap/mod_ldap.c +++ b/src/mod/directories/mod_ldap/mod_ldap.c @@ -220,10 +220,10 @@ static switch_loadable_module_interface_t skel_module_interface = { /*.directory_interface */ &ldap_directory_interface }; -switch_status_t switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +switch_status_t switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &skel_module_interface; + *module_interface = &skel_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/endpoints/mod_dingaling/mod_dingaling.c b/src/mod/endpoints/mod_dingaling/mod_dingaling.c index b9b130c2ef..056a813d15 100644 --- a/src/mod/endpoints/mod_dingaling/mod_dingaling.c +++ b/src/mod/endpoints/mod_dingaling/mod_dingaling.c @@ -1105,7 +1105,7 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session, } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { if (switch_core_new_memory_pool(&module_pool) != SWITCH_STATUS_SUCCESS) { @@ -1116,7 +1116,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod load_config(); /* connect my internal structure to the blank pointer passed to me */ - *interface = &channel_module_interface; + *module_interface = &channel_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/endpoints/mod_exosip/mod_exosip.c b/src/mod/endpoints/mod_exosip/mod_exosip.c index 07dd8458cf..8d46905464 100644 --- a/src/mod/endpoints/mod_exosip/mod_exosip.c +++ b/src/mod/endpoints/mod_exosip/mod_exosip.c @@ -1071,7 +1071,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void) return SWITCH_STATUS_SUCCESS; } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* NOTE: **interface is **_interface because the common lib redefines interface to struct in some situations */ @@ -1085,7 +1085,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod switch_core_hash_init(&globals.srtp_hash, module_pool); /* connect my internal structure to the blank pointer passed to me */ - *interface = &exosip_module_interface; + *module_interface = &exosip_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/endpoints/mod_iax/mod_iax.c b/src/mod/endpoints/mod_iax/mod_iax.c index d8a169f562..c3c78233e5 100644 --- a/src/mod/endpoints/mod_iax/mod_iax.c +++ b/src/mod/endpoints/mod_iax/mod_iax.c @@ -790,7 +790,7 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session, } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { if (switch_core_new_memory_pool(&module_pool) != SWITCH_STATUS_SUCCESS) { @@ -799,7 +799,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod } /* connect my internal structure to the blank pointer passed to me */ - *interface = &channel_module_interface; + *module_interface = &channel_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/endpoints/mod_portaudio/mod_portaudio.c b/src/mod/endpoints/mod_portaudio/mod_portaudio.c index 601856a5ea..0f52dedf31 100644 --- a/src/mod/endpoints/mod_portaudio/mod_portaudio.c +++ b/src/mod/endpoints/mod_portaudio/mod_portaudio.c @@ -523,7 +523,7 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session, } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { if (switch_core_new_memory_pool(&module_pool) != SWITCH_STATUS_SUCCESS) { @@ -545,7 +545,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod } /* connect my internal structure to the blank pointer passed to me */ - *interface = &channel_module_interface; + *module_interface = &channel_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/endpoints/mod_woomera/mod_woomera.c b/src/mod/endpoints/mod_woomera/mod_woomera.c index 2809d32201..974b3fd4b5 100644 --- a/src/mod/endpoints/mod_woomera/mod_woomera.c +++ b/src/mod/endpoints/mod_woomera/mod_woomera.c @@ -1298,7 +1298,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void) return SWITCH_STATUS_SUCCESS; } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { switch_config_t cfg; @@ -1373,7 +1373,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod /* connect my internal structure to the blank pointer passed to me */ - *interface = &woomerachan_module_interface; + *module_interface = &woomerachan_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/event_handlers/mod_event_multicast/mod_event_multicast.c b/src/mod/event_handlers/mod_event_multicast/mod_event_multicast.c index 8169aabdc3..9f8abdd22d 100644 --- a/src/mod/event_handlers/mod_event_multicast/mod_event_multicast.c +++ b/src/mod/event_handlers/mod_event_multicast/mod_event_multicast.c @@ -115,7 +115,7 @@ static switch_loadable_module_interface_t event_test_module_interface = { }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { memset(&globals, 0, sizeof(globals)); @@ -159,7 +159,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod /* connect my internal structure to the blank pointer passed to me */ - *interface = &event_test_module_interface; + *module_interface = &event_test_module_interface; if (switch_event_bind((char *) modname, SWITCH_EVENT_ALL, SWITCH_EVENT_SUBCLASS_ANY, event_handler, NULL) != SWITCH_STATUS_SUCCESS) { diff --git a/src/mod/event_handlers/mod_event_test/mod_event_test.c b/src/mod/event_handlers/mod_event_test/mod_event_test.c index 42e9514e4b..e829c0d42d 100644 --- a/src/mod/event_handlers/mod_event_test/mod_event_test.c +++ b/src/mod/event_handlers/mod_event_test/mod_event_test.c @@ -105,10 +105,10 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void) #endif -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &event_test_module_interface; + *module_interface = &event_test_module_interface; if (switch_event_reserve_subclass(MY_EVENT_COOL) != SWITCH_STATUS_SUCCESS) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Couldn't register subclass!"); diff --git a/src/mod/event_handlers/mod_xmpp_event/mod_xmpp_event.c b/src/mod/event_handlers/mod_xmpp_event/mod_xmpp_event.c index a3a69257b3..84098ffb58 100644 --- a/src/mod/event_handlers/mod_xmpp_event/mod_xmpp_event.c +++ b/src/mod/event_handlers/mod_xmpp_event/mod_xmpp_event.c @@ -355,10 +355,10 @@ static switch_loadable_module_interface_t xmpp_event_module_interface = { /*.application_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &xmpp_event_module_interface; + *module_interface = &xmpp_event_module_interface; if (load_config() != SWITCH_STATUS_SUCCESS) { return SWITCH_STATUS_FALSE; diff --git a/src/mod/event_handlers/mod_zeroconf/mod_zeroconf.c b/src/mod/event_handlers/mod_zeroconf/mod_zeroconf.c index caac40e005..43120151f4 100644 --- a/src/mod/event_handlers/mod_zeroconf/mod_zeroconf.c +++ b/src/mod/event_handlers/mod_zeroconf/mod_zeroconf.c @@ -264,7 +264,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void) } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { memset(&globals, 0, sizeof(globals)); @@ -296,7 +296,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod } /* connect my internal structure to the blank pointer passed to me */ - *interface = &zeroconf_module_interface; + *module_interface = &zeroconf_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/formats/mod_sndfile/mod_sndfile.c b/src/mod/formats/mod_sndfile/mod_sndfile.c index 8d74697a99..9096cbd60a 100644 --- a/src/mod/formats/mod_sndfile/mod_sndfile.c +++ b/src/mod/formats/mod_sndfile/mod_sndfile.c @@ -309,7 +309,7 @@ static switch_status_t setup_formats(void) return SWITCH_STATUS_SUCCESS; } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { @@ -319,7 +319,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod /* connect my internal structure to the blank pointer passed to me */ sndfile_file_interface.extens = supported_formats; - *interface = &sndfile_module_interface; + *module_interface = &sndfile_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/languages/mod_perl/mod_perl.c b/src/mod/languages/mod_perl/mod_perl.c index 36f8ba321c..7754d35b49 100644 --- a/src/mod/languages/mod_perl/mod_perl.c +++ b/src/mod/languages/mod_perl/mod_perl.c @@ -110,7 +110,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void) return SWITCH_STATUS_SUCCESS; } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { PerlInterpreter *my_perl; @@ -133,7 +133,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod /* connect my internal structure to the blank pointer passed to me */ - *interface = &perl_module_interface; + *module_interface = &perl_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c b/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c index a4fcd2f5de..5f2def4c21 100644 --- a/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c +++ b/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c @@ -2190,7 +2190,7 @@ static switch_loadable_module_interface_t spidermonkey_module_interface = { /*.directory_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { switch_status_t status; @@ -2199,7 +2199,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod } /* connect my internal structure to the blank pointer passed to me */ - *interface = &spidermonkey_module_interface; + *module_interface = &spidermonkey_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/mod/loggers/mod_console/mod_console.c b/src/mod/loggers/mod_console/mod_console.c index 22de4e88eb..7b14e4a5a1 100644 --- a/src/mod/loggers/mod_console/mod_console.c +++ b/src/mod/loggers/mod_console/mod_console.c @@ -134,7 +134,7 @@ static switch_status_t switch_console_logger(const switch_log_node_t *node, swit return SWITCH_STATUS_SUCCESS; } -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { if (switch_core_new_memory_pool(&module_pool) != SWITCH_STATUS_SUCCESS) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "OH OH no pool\n"); @@ -143,7 +143,7 @@ SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_mod /* connect my internal structure to the blank pointer passed to me */ - *interface = &console_module_interface; + *module_interface = &console_module_interface; /* setup my logger function */ switch_log_bind_logger(switch_console_logger, SWITCH_LOG_DEBUG); diff --git a/src/mod/timers/mod_softtimer/mod_softtimer.c b/src/mod/timers/mod_softtimer/mod_softtimer.c index 1923389fe7..3a30e5713e 100644 --- a/src/mod/timers/mod_softtimer/mod_softtimer.c +++ b/src/mod/timers/mod_softtimer/mod_softtimer.c @@ -113,11 +113,11 @@ static const switch_loadable_module_interface_t mod_timers_module_interface = { /*.switch_application_interface */ NULL }; -SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename) +SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **module_interface, char *filename) { /* connect my internal structure to the blank pointer passed to me */ - *interface = &mod_timers_module_interface; + *module_interface = &mod_timers_module_interface; /* indicate that the module should continue to be loaded */ return SWITCH_STATUS_SUCCESS; diff --git a/src/switch_loadable_module.c b/src/switch_loadable_module.c index 13d8308d49..325c5e7142 100644 --- a/src/switch_loadable_module.c +++ b/src/switch_loadable_module.c @@ -34,7 +34,7 @@ struct switch_loadable_module { char *filename; - const switch_loadable_module_interface_t *interface; + const switch_loadable_module_interface_t *module_interface; void *lib; switch_module_load_t switch_module_load; switch_module_runtime_t switch_module_runtime; @@ -72,11 +72,11 @@ static void *switch_loadable_module_exec(switch_thread_t *thread, void *obj) for (restarts = 0; status != SWITCH_STATUS_TERM; restarts++) { status = module->switch_module_runtime(); } - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Thread ended for %s\n", module->interface->module_name); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Thread ended for %s\n", module->module_interface->module_name); if (ts->pool) { switch_memory_pool_t *pool = ts->pool; - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Destroying Pool for %s\n", module->interface->module_name); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Destroying Pool for %s\n", module->module_interface->module_name); switch_core_destroy_memory_pool(&pool); } switch_yield(1000000); @@ -93,19 +93,19 @@ static switch_status_t switch_loadable_module_process(char *key, switch_loadable switch_core_hash_insert(loadable_modules.module_hash, key, new_module); - if (new_module->interface->endpoint_interface) { + if (new_module->module_interface->endpoint_interface) { const switch_endpoint_interface_t *ptr; - for (ptr = new_module->interface->endpoint_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->endpoint_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Endpoint '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.endpoint_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->codec_interface) { + if (new_module->module_interface->codec_interface) { const switch_codec_implementation_t *impl; const switch_codec_interface_t *ptr; - for (ptr = new_module->interface->codec_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->codec_interface; ptr; ptr = ptr->next) { for (impl = ptr->implementations; impl; impl = impl->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Codec '%s' (%s) %dkhz %dms\n", @@ -118,47 +118,47 @@ static switch_status_t switch_loadable_module_process(char *key, switch_loadable } } - if (new_module->interface->dialplan_interface) { + if (new_module->module_interface->dialplan_interface) { const switch_dialplan_interface_t *ptr; - for (ptr = new_module->interface->dialplan_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->dialplan_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Dialplan '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.dialplan_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->timer_interface) { + if (new_module->module_interface->timer_interface) { const switch_timer_interface_t *ptr; - for (ptr = new_module->interface->timer_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->timer_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Timer '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.timer_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->application_interface) { + if (new_module->module_interface->application_interface) { const switch_application_interface_t *ptr; - for (ptr = new_module->interface->application_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->application_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Application '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.application_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->api_interface) { + if (new_module->module_interface->api_interface) { const switch_api_interface_t *ptr; - for (ptr = new_module->interface->api_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->api_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding API Function '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.api_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->file_interface) { + if (new_module->module_interface->file_interface) { const switch_file_interface_t *ptr; - for (ptr = new_module->interface->file_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->file_interface; ptr; ptr = ptr->next) { int i; for (i = 0; ptr->extens[i]; i++) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding File Format '%s'\n", ptr->extens[i]); @@ -167,19 +167,19 @@ static switch_status_t switch_loadable_module_process(char *key, switch_loadable } } - if (new_module->interface->speech_interface) { + if (new_module->module_interface->speech_interface) { const switch_speech_interface_t *ptr; - for (ptr = new_module->interface->speech_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->speech_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Speech interface '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.speech_hash, (char *) ptr->interface_name, (void *) ptr); } } - if (new_module->interface->directory_interface) { + if (new_module->module_interface->directory_interface) { const switch_directory_interface_t *ptr; - for (ptr = new_module->interface->directory_interface; ptr; ptr = ptr->next) { + for (ptr = new_module->module_interface->directory_interface; ptr; ptr = ptr->next) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Directory interface '%s'\n", ptr->interface_name); switch_core_hash_insert(loadable_modules.directory_hash, (char *) ptr->interface_name, (void *) ptr); } @@ -199,7 +199,7 @@ static switch_status_t switch_loadable_module_load_file(char *filename, switch_l switch_module_load_t load_func_ptr = NULL; int loading = 1; const char *err = NULL; - switch_loadable_module_interface_t *interface = NULL; + switch_loadable_module_interface_t *module_interface = NULL; char derr[512] = ""; assert(filename != NULL); @@ -222,9 +222,9 @@ static switch_status_t switch_loadable_module_load_file(char *filename, switch_l break; } - if (load_func_ptr(&interface, filename) != SWITCH_STATUS_SUCCESS) { + if (load_func_ptr(&module_interface, filename) != SWITCH_STATUS_SUCCESS) { err = "Module load routine returned an error"; - interface = NULL; + module_interface = NULL; break; } @@ -242,7 +242,7 @@ static switch_status_t switch_loadable_module_load_file(char *filename, switch_l } module->filename = switch_core_permenant_strdup(filename); - module->interface = interface; + module->module_interface = module_interface; module->switch_module_load = load_func_ptr; if ((status = apr_dso_sym(&function_handle, dso, "switch_module_shutdown")) == APR_SUCCESS) { @@ -260,7 +260,7 @@ static switch_status_t switch_loadable_module_load_file(char *filename, switch_l } *new_module = module; - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Successfully Loaded [%s]\n", interface->module_name); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Successfully Loaded [%s]\n", module_interface->module_name); return SWITCH_STATUS_SUCCESS; @@ -321,7 +321,7 @@ SWITCH_DECLARE(switch_status_t) switch_loadable_module_build_dynamic(char *filen switch_module_load_t load_func_ptr = NULL; int loading = 1; const char *err = NULL; - switch_loadable_module_interface_t *interface = NULL; + switch_loadable_module_interface_t *module_interface = NULL; if ((module = switch_core_permenant_alloc(sizeof(switch_loadable_module_t))) == 0) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Couldn't allocate memory\n"); @@ -336,9 +336,9 @@ SWITCH_DECLARE(switch_status_t) switch_loadable_module_build_dynamic(char *filen break; } - if (load_func_ptr(&interface, filename) != SWITCH_STATUS_SUCCESS) { + if (load_func_ptr(&module_interface, filename) != SWITCH_STATUS_SUCCESS) { err = "Module load routine returned an error"; - interface = NULL; + module_interface = NULL; break; } @@ -356,7 +356,7 @@ SWITCH_DECLARE(switch_status_t) switch_loadable_module_build_dynamic(char *filen } module->filename = switch_core_permenant_strdup(filename); - module->interface = interface; + module->module_interface = module_interface; module->switch_module_load = load_func_ptr; if (switch_module_shutdown) { @@ -368,7 +368,7 @@ SWITCH_DECLARE(switch_status_t) switch_loadable_module_build_dynamic(char *filen if (module->switch_module_runtime) { switch_core_launch_thread(switch_loadable_module_exec, module, loadable_modules.pool); } - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Successfully Loaded [%s]\n", interface->module_name); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Successfully Loaded [%s]\n", module_interface->module_name); return switch_loadable_module_process((char *) module->filename, module); } @@ -511,7 +511,7 @@ SWITCH_DECLARE(void) switch_loadable_module_shutdown(void) for (hi = switch_hash_first(loadable_modules.pool, loadable_modules.module_hash); hi; hi = switch_hash_next(hi)) { switch_hash_this(hi, NULL, NULL, &val); module = (switch_loadable_module_t *) val; - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Checking %s\t", module->interface->module_name); + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Checking %s\t", module->module_interface->module_name); if (module->switch_module_shutdown) { switch_log_printf(SWITCH_CHANNEL_LOG_CLEAN, SWITCH_LOG_CONSOLE, "(yes)\n"); module->switch_module_shutdown();