summaryrefslogtreecommitdiff
path: root/source4/scripting/ejs/smbcalls.c
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2005-12-26 21:58:31 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:47:46 -0500
commit09c44f6cae89621871d2e5475b0c0f99c25804b4 (patch)
tree053b1712c035bb63361bf549ba3bf13491412c3c /source4/scripting/ejs/smbcalls.c
parent6aafed9600a3fa05932668c70fc0e20f3724dab6 (diff)
downloadsamba-09c44f6cae89621871d2e5475b0c0f99c25804b4.tar.gz
samba-09c44f6cae89621871d2e5475b0c0f99c25804b4.tar.bz2
samba-09c44f6cae89621871d2e5475b0c0f99c25804b4.zip
r12500: Use init functions explicitly in a few more places. 'gensec' and 'librpc'
are the only two subsystems left to convert. (This used to be commit f6bbc72996aeee8607fc583140fd60be0e06e969)
Diffstat (limited to 'source4/scripting/ejs/smbcalls.c')
-rw-r--r--source4/scripting/ejs/smbcalls.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/source4/scripting/ejs/smbcalls.c b/source4/scripting/ejs/smbcalls.c
index 3e5035b272..ee999402a5 100644
--- a/source4/scripting/ejs/smbcalls.c
+++ b/source4/scripting/ejs/smbcalls.c
@@ -24,6 +24,7 @@
#include "includes.h"
#include "lib/appweb/ejs/ejs.h"
#include "scripting/ejs/smbcalls.h"
+#include "smb_build.h"
/*
return the type of a variable
@@ -116,6 +117,9 @@ static int ejs_libinclude(int eid, int argc, char **argv)
*/
void smb_setup_ejs_functions(void)
{
+ init_module_fn static_init[] = STATIC_SMBCALLS_MODULES;
+ init_module_fn *shared_init;
+
smb_setup_ejs_config();
smb_setup_ejs_ldb();
smb_setup_ejs_nbt();
@@ -131,8 +135,16 @@ void smb_setup_ejs_functions(void)
smb_setup_ejs_samba3();
smb_setup_ejs_param();
smb_setup_ejs_datablob();
+
ejsnet_setup();
+ shared_init = load_samba_modules(NULL, "ejs");
+
+ run_init_functions(static_init);
+ run_init_functions(shared_init);
+
+ talloc_free(shared_init);
+
ejsDefineCFunction(-1, "typeof", ejs_typeof, NULL, MPR_VAR_SCRIPT_HANDLE);
ejsDefineStringCFunction(-1, "libinclude", ejs_libinclude, NULL, MPR_VAR_SCRIPT_HANDLE);
}