|
@@ -116,13 +116,13 @@ static pv_export_t mod_pvs[] = {
|
|
|
};
|
|
|
|
|
|
static param_export_t params[] = {
|
|
|
- { "db_url", STR_PARAM, &xcaps_db_url.s },
|
|
|
- { "xcap_table", STR_PARAM, &xcaps_db_table.s },
|
|
|
- { "xcap_root", STR_PARAM, &xcaps_root.s },
|
|
|
+ { "db_url", PARAM_STR, &xcaps_db_url },
|
|
|
+ { "xcap_table", PARAM_STR, &xcaps_db_table },
|
|
|
+ { "xcap_root", PARAM_STR, &xcaps_root },
|
|
|
{ "buf_size", INT_PARAM, &xcaps_buf.len },
|
|
|
- { "xml_ns", STR_PARAM|USE_FUNC_PARAM, (void*)xcaps_xpath_ns_param },
|
|
|
+ { "xml_ns", PARAM_STRING|USE_FUNC_PARAM, (void*)xcaps_xpath_ns_param },
|
|
|
{ "directory_scheme", INT_PARAM, &xcaps_directory_scheme },
|
|
|
- { "directory_hostname", STR_PARAM, &xcaps_directory_hostname.s },
|
|
|
+ { "directory_hostname", PARAM_STR, &xcaps_directory_hostname },
|
|
|
{ 0, 0, 0 }
|
|
|
};
|
|
|
|
|
@@ -159,13 +159,6 @@ struct module_exports exports= {
|
|
|
static int mod_init(void)
|
|
|
{
|
|
|
|
|
|
- xcaps_db_url.len = (xcaps_db_url.s) ? strlen(xcaps_db_url.s) : 0;
|
|
|
- xcaps_db_table.len = (xcaps_db_table.s) ? strlen(xcaps_db_table.s) : 0;
|
|
|
- xcaps_root.len = (xcaps_root.s) ? strlen(xcaps_root.s) : 0;
|
|
|
- xcaps_directory_hostname.len
|
|
|
- = xcaps_directory_hostname.s
|
|
|
- ? strlen(xcaps_directory_hostname.s) : 0;
|
|
|
-
|
|
|
if (xcaps_directory_scheme < -1 || xcaps_directory_scheme > 1)
|
|
|
{
|
|
|
LM_ERR("invalid xcaps_directory_scheme\n");
|