diff options
author | Zhidao HONG <z.hong@f5.com> | 2023-05-08 16:00:25 +0800 |
---|---|---|
committer | Zhidao HONG <z.hong@f5.com> | 2023-05-08 16:00:25 +0800 |
commit | a3c3a29493798873ad04922bb2a7180b2ce267d5 (patch) | |
tree | 4332cbb50520c389d859db27e7266ffa53954b92 /src/nxt_tstr.c | |
parent | 56af7bb825c286e1a397f780bff9da275e5602ad (diff) | |
download | unit-a3c3a29493798873ad04922bb2a7180b2ce267d5.tar.gz unit-a3c3a29493798873ad04922bb2a7180b2ce267d5.tar.bz2 |
NJS: supported loadable modules.
Diffstat (limited to 'src/nxt_tstr.c')
-rw-r--r-- | src/nxt_tstr.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/nxt_tstr.c b/src/nxt_tstr.c index c439696e..516415d9 100644 --- a/src/nxt_tstr.c +++ b/src/nxt_tstr.c @@ -70,7 +70,7 @@ nxt_tstr_state_new(nxt_mp_t *mp, nxt_bool_t test) } #if (NXT_HAVE_NJS) - state->jcf = nxt_js_conf_new(mp); + state->jcf = nxt_js_conf_new(mp, test); if (nxt_slow_path(state->jcf == NULL)) { return NULL; } @@ -273,7 +273,8 @@ nxt_tstr_query(nxt_task_t *task, nxt_tstr_query_t *query, nxt_tstr_t *tstr, } else { #if (NXT_HAVE_NJS) - ret = nxt_js_call(task, &query->cache->js, tstr->u.js, val, query->ctx); + ret = nxt_js_call(task, query->state->jcf, &query->cache->js, + tstr->u.js, val, query->ctx); if (nxt_slow_path(ret != NXT_OK)) { query->failed = 1; |