summaryrefslogtreecommitdiffhomepage
path: root/src/nxt_script.c
diff options
context:
space:
mode:
authorAndrei Zeliankou <zelenkov@nginx.com>2024-02-16 18:22:35 +0000
committerandrey-zelenkov <xim.andrew@gmail.com>2024-03-12 16:56:11 +0000
commit9993814d14fa693dc8641c31bca70223895d2055 (patch)
tree1845a910be997cdd2678bcd0bbfe8113ba5e5305 /src/nxt_script.c
parentabcfc4cd6871c57af05fa2ee1c3fe80dfc556cdc (diff)
downloadunit-9993814d14fa693dc8641c31bca70223895d2055.tar.gz
unit-9993814d14fa693dc8641c31bca70223895d2055.tar.bz2
NJS: loader should be registered using njs_vm_set_module_loader()
This change makes NJS module incompatible with NJS older than 0.8.3. Therefore, the configuration version check has been adjusted accordingly. This change was introduced in NJS 0.8.3 here: <https://hg.nginx.com/njs/rev/ad1a7ad3c715>
Diffstat (limited to 'src/nxt_script.c')
-rw-r--r--src/nxt_script.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/src/nxt_script.c b/src/nxt_script.c
index 70045a22..05d9561d 100644
--- a/src/nxt_script.c
+++ b/src/nxt_script.c
@@ -37,14 +37,6 @@ static void nxt_script_buf_completion(nxt_task_t *task, void *obj, void *data);
static nxt_lvlhsh_t nxt_script_info;
-static njs_vm_ops_t nxt_js_ops = {
- NULL,
- NULL,
- nxt_js_module_loader,
- NULL,
-};
-
-
nxt_script_t *
nxt_script_new(nxt_task_t *task, nxt_str_t *name, u_char *data, size_t size,
u_char *error)
@@ -63,8 +55,6 @@ nxt_script_new(nxt_task_t *task, nxt_str_t *name, u_char *data, size_t size,
opts.file.start = (u_char *) "default";
opts.file.length = 7;
- opts.ops = &nxt_js_ops;
-
vm = njs_vm_create(&opts);
if (nxt_slow_path(vm == NULL)) {
return NULL;