summaryrefslogtreecommitdiffhomepage
path: root/src/nxt_controller.c
diff options
context:
space:
mode:
authorMax Romanov <max.romanov@nginx.com>2019-03-22 15:32:40 +0300
committerMax Romanov <max.romanov@nginx.com>2019-03-22 15:32:40 +0300
commit1b7514dca386e26503eac90bd3518a950d7f9a5c (patch)
tree7c7ef7ecbe3ebf040c7386c69b103099e0bd2e0c /src/nxt_controller.c
parent687f83fbd00b4f72da06f497f5bfe2af06716a3a (diff)
downloadunit-1b7514dca386e26503eac90bd3518a950d7f9a5c.tar.gz
unit-1b7514dca386e26503eac90bd3518a950d7f9a5c.tar.bz2
Destroying pool in case of error.
This closes #233 issue on GitHub. Thanks to 洪志道 (Hong Zhi Dao).
Diffstat (limited to 'src/nxt_controller.c')
-rw-r--r--src/nxt_controller.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nxt_controller.c b/src/nxt_controller.c
index 29838bd9..d5534f49 100644
--- a/src/nxt_controller.c
+++ b/src/nxt_controller.c
@@ -184,6 +184,7 @@ nxt_controller_start(nxt_task_t *task, void *data)
vldt.pool = nxt_mp_create(1024, 128, 256, 32);
if (nxt_slow_path(vldt.pool == NULL)) {
+ nxt_mp_destroy(mp);
return NXT_ERROR;
}