Freed mmap memory filled with 0xA5.
This commit is contained in:
@@ -76,6 +76,10 @@ nxt_port_mmaps_destroy(nxt_array_t *port_mmaps, nxt_bool_t destroy_pool)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#define nxt_port_mmap_free_junk(p, size) \
|
||||||
|
memset((p), 0xA5, size)
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
nxt_port_mmap_buf_completion(nxt_task_t *task, void *obj, void *data)
|
nxt_port_mmap_buf_completion(nxt_task_t *task, void *obj, void *data)
|
||||||
{
|
{
|
||||||
@@ -119,6 +123,8 @@ nxt_port_mmap_buf_completion(nxt_task_t *task, void *obj, void *data)
|
|||||||
c = nxt_port_mmap_chunk_id(hdr, p);
|
c = nxt_port_mmap_chunk_id(hdr, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
nxt_port_mmap_free_junk(p, b->mem.end - p);
|
||||||
|
|
||||||
while (p < b->mem.end) {
|
while (p < b->mem.end) {
|
||||||
nxt_port_mmap_set_chunk_free(hdr, c);
|
nxt_port_mmap_set_chunk_free(hdr, c);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user