aboutsummaryrefslogtreecommitdiff
path: root/src/njs_chb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/njs_chb.c')
-rw-r--r--src/njs_chb.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/njs_chb.c b/src/njs_chb.c
index 3ee28009..ac88c0bd 100644
--- a/src/njs_chb.c
+++ b/src/njs_chb.c
@@ -251,7 +251,11 @@ njs_chb_destroy(njs_chb_t *chain)
while (n != NULL) {
next = n->next;
- chain->free(chain->pool, n);
+
+ if (chain->free != NULL) {
+ chain->free(chain->pool, n);
+ }
+
n = next;
}
}