NJS: adding the missing vm destruction.

This commit fixed the njs memory leak happened in the config validation, updating and http requests.
This commit is contained in:
Zhidao HONG
2023-01-30 11:16:01 +08:00
parent cbc01907fe
commit 789762ff3d
8 changed files with 69 additions and 4 deletions

View File

@@ -833,6 +833,10 @@ nxt_http_request_close_handler(nxt_task_t *task, void *obj, void *data)
r->body->file->fd = -1;
}
if (r->tstr_query != NULL) {
nxt_tstr_query_release(r->tstr_query);
}
if (nxt_fast_path(proto.any != NULL)) {
protocol = r->protocol;