Welcome! Log In Create A New Profile

Advanced

[njs] A possible memory leak has been fixed.

October 31, 2016 09:12AM
details: http://hg.nginx.org/njs/rev/f0ac27f59e58
branches:
changeset: 230:f0ac27f59e58
user: Igor Sysoev <igor@sysoev.ru>
date: Mon Oct 31 15:51:12 2016 +0300
description:
A possible memory leak has been fixed.

Thanks to ??? (Hong Zhi Dao).

diffstat:

nxt/nxt_mem_cache_pool.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)

diffs (19 lines):

diff -r a1cd4104df67 -r f0ac27f59e58 nxt/nxt_mem_cache_pool.c
--- a/nxt/nxt_mem_cache_pool.c Sat Oct 29 00:04:29 2016 +0300
+++ b/nxt/nxt_mem_cache_pool.c Mon Oct 31 15:51:12 2016 +0300
@@ -574,14 +574,13 @@ nxt_mem_cache_alloc_large(nxt_mem_cache_

} else {
block = pool->proto->alloc(pool->mem, sizeof(nxt_mem_cache_block_t));
-
if (nxt_slow_path(block == NULL)) {
- pool->proto->free(pool->mem, block);
return NULL;
}

p = pool->proto->align(pool->mem, alignment, size);
if (nxt_slow_path(p == NULL)) {
+ pool->proto->free(pool->mem, block);
return NULL;
}


_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[njs] A possible memory leak has been fixed.

Igor Sysoev 578 October 31, 2016 09:12AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 59
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready