Browse Source

app_python:
- fixed runtime warning: exports dlflags interface is deprecated and it will not be supported in newer versions; consider using mod_register() instead
- python routines can be called in any routes.

Konstantin Mosesov 12 years ago
parent
commit
4cc713182c
1 changed files with 3 additions and 3 deletions
  1. 3 3
      modules/app_python/python_mod.c

+ 3 - 3
modules/app_python/python_mod.c

@@ -66,15 +66,15 @@ static param_export_t params[]={
  * Exported functions
  */
 static cmd_export_t cmds[] = {
-    { "python_exec", (cmd_function)python_exec1, 1,  NULL, 0,	REQUEST_ROUTE | FAILURE_ROUTE  | ONREPLY_ROUTE | BRANCH_ROUTE },
-    { "python_exec", (cmd_function)python_exec2, 2,  NULL, 0,	REQUEST_ROUTE | FAILURE_ROUTE  | ONREPLY_ROUTE | BRANCH_ROUTE },
+    { "python_exec", (cmd_function)python_exec1, 1,  NULL, 0,	ANY_ROUTE },
+    { "python_exec", (cmd_function)python_exec2, 2,  NULL, 0,	ANY_ROUTE },
     { 0, 0, 0, 0, 0, 0 }
 };
 
 /** module exports */
 struct module_exports exports = {
     "app_python",                   /* module name */
-    RTLD_NOW | RTLD_GLOBAL,         /* dlopen flags */
+    DEFAULT_DLFLAGS,                /* dlopen flags */
     cmds,                           /* exported functions */
     params,                         /* exported parameters */
     0,                              /* exported statistics */