[BugFix] chunk_alloc pass NULL to buflib_shrink

old_chunk has already been unpinned therefore the address
could be incorrect
NULL will ensure buflib_shrink uses the same start address

Change-Id: I9371e4f8263c6e5bf769108a8558dc938d4c8b87
This commit is contained in:
William Wilgus 2023-02-22 10:55:10 -05:00 committed by William Wilgus
parent 4faffe0a9c
commit b6d04d1ac0

View file

@ -114,7 +114,7 @@ bool chunk_realloc(struct chunk_alloc_header *hdr,
logf("%s shrink existing chunk array", __func__);
min_chunk = max_chunks;
buflib_shrink(ctx, hdr->chunk_handle,
old_chunk, CHUNK_ARRSZ(max_chunks));
NULL, CHUNK_ARRSZ(max_chunks));
new_handle = hdr->chunk_handle;
}