[svn-commits] junky: trunk r115594 - in /trunk/apps: app_jack.c app_skel.c
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Fri May 9 22:28:50 CDT 2008
Author: junky
Date: Fri May 9 22:28:50 2008
New Revision: 115594
URL: http://svn.digium.com/view/asterisk?view=rev&rev=115594
Log:
ameliorate load and unload to dont use DECLINED or FAILED, when theres no .conf involved.
Modified:
trunk/apps/app_jack.c
trunk/apps/app_skel.c
Modified: trunk/apps/app_jack.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_jack.c?view=diff&rev=115594&r1=115593&r2=115594
==============================================================================
--- trunk/apps/app_jack.c (original)
+++ trunk/apps/app_jack.c Fri May 9 22:28:50 2008
@@ -977,15 +977,12 @@
static int load_module(void)
{
- if (ast_register_application(jack_app, jack_exec, jack_synopsis, jack_desc))
- return AST_MODULE_LOAD_DECLINE;
-
- if (ast_custom_function_register(&jack_hook_function)) {
- ast_unregister_application(jack_app);
- return AST_MODULE_LOAD_DECLINE;
- }
-
- return AST_MODULE_LOAD_SUCCESS;
+ int res = 0;
+
+ res |= ast_register_application(jack_app, jack_exec, jack_synopsis, jack_desc);
+ res |= ast_custom_function_register(&jack_hook_function);
+
+ return res;
}
AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "JACK Interface");
Modified: trunk/apps/app_skel.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_skel.c?view=diff&rev=115594&r1=115593&r2=115594
==============================================================================
--- trunk/apps/app_skel.c (original)
+++ trunk/apps/app_skel.c Fri May 9 22:28:50 2008
@@ -109,17 +109,12 @@
static int unload_module(void)
{
- int res;
- res = ast_unregister_application(app);
- return res;
+ return ast_unregister_application(app);
}
static int load_module(void)
{
- if (ast_register_application(app, app_exec, synopsis, descrip))
- return AST_MODULE_LOAD_DECLINE;
-
- return AST_MODULE_LOAD_SUCCESS;
+ return ast_register_application(app, app_exec, synopsis, descrip);
}
AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Skeleton (sample) Application");
More information about the svn-commits
mailing list