curl resource engine More...

Go to the source code of this file.
Functions | |
| static void | __reg_module (void) |
| static void | __unreg_module (void) |
| static int | load_module (void) |
| static int | unload_module (void) |
Variables | |
| static struct ast_module_info | __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "cURL Resource Module" , .key = "This paragraph is copyright (c) 2006 by Digium, Inc. \In order for your module to load, it must return this \key via a function called \"key\". Any code which \includes this paragraph must be licensed under the GNU \General Public License version 2 or later (at your \option). In addition to Digium's general reservations \of rights, Digium expressly reserves the right to \allow other parties to license this paragraph under \different terms. Any use of Digium, Inc. trademarks or \logos (including \"Asterisk\" or \"Digium\") without \express written permission of Digium, Inc. is prohibited.\n" , .buildopt_sum = AST_BUILDOPT_SUM, .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_REALTIME_DEPEND, } |
| static struct ast_module_info * | ast_module_info = &__mod_info |
curl resource engine
Definition in file res_curl.c.
| static void __reg_module | ( | void | ) | [static] |
Definition at line 78 of file res_curl.c.
| static void __unreg_module | ( | void | ) | [static] |
Definition at line 78 of file res_curl.c.
| static int load_module | ( | void | ) | [static] |
Definition at line 62 of file res_curl.c.
References ast_log(), AST_MODULE_LOAD_DECLINE, and LOG_ERROR.
{
int res = 0;
if (curl_global_init(CURL_GLOBAL_ALL)) {
ast_log(LOG_ERROR, "Unable to initialize the CURL library. Cannot load res_curl\n");
return AST_MODULE_LOAD_DECLINE;
}
return res;
}
| static int unload_module | ( | void | ) | [static] |
Definition at line 42 of file res_curl.c.
References ast_log(), ast_module_check(), and LOG_ERROR.
{
int res = 0;
/* If the dependent modules are still in memory, forbid unload */
if (ast_module_check("func_curl.so")) {
ast_log(LOG_ERROR, "func_curl.so (dependent module) is still loaded. Cannot unload res_curl.so\n");
return -1;
}
if (ast_module_check("res_config_curl.so")) {
ast_log(LOG_ERROR, "res_config_curl.so (dependent module) is still loaded. Cannot unload res_curl.so\n");
return -1;
}
curl_global_cleanup();
return res;
}
struct ast_module_info __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "cURL Resource Module" , .key = "This paragraph is copyright (c) 2006 by Digium, Inc. \In order for your module to load, it must return this \key via a function called \"key\". Any code which \includes this paragraph must be licensed under the GNU \General Public License version 2 or later (at your \option). In addition to Digium's general reservations \of rights, Digium expressly reserves the right to \allow other parties to license this paragraph under \different terms. Any use of Digium, Inc. trademarks or \logos (including \"Asterisk\" or \"Digium\") without \express written permission of Digium, Inc. is prohibited.\n" , .buildopt_sum = AST_BUILDOPT_SUM, .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_REALTIME_DEPEND, } [static] |
Definition at line 78 of file res_curl.c.
struct ast_module_info* ast_module_info = &__mod_info [static] |
Definition at line 78 of file res_curl.c.