From: Liam R. Howlett Date: Wed, 17 Sep 2025 01:01:06 +0000 (-0400) Subject: cp_data_write: Fix dst_size to be split + 1 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=8c62b04fa996e28b2e88bf679e1945a75b645354;p=users%2Fjedix%2Flinux-maple.git cp_data_write: Fix dst_size to be split + 1 Signed-off-by: Liam R. Howlett --- diff --git a/lib/maple_tree.c b/lib/maple_tree.c index 0a0ea2bf0ab5..295fee1456ea 100644 --- a/lib/maple_tree.c +++ b/lib/maple_tree.c @@ -3246,13 +3246,12 @@ void cp_data_write(struct maple_copy *cp, struct ma_state *mas) s_max = cp->src[s].max; s_mt = cp->src[s].mt; d_mt = cp->dst[d].mt; - dst_size = split + 1; do { dst_offset = 0; d_max = 0; dst = cp->dst[d].node; d_mt = cp->dst[d].mt; - dst_size = split; + dst_size = split + 1; while (dst_size) { unsigned char size;