diff --git a/src/htx.c b/src/htx.c index 5e2a8ba04..cc0b6d1d4 100644 --- a/src/htx.c +++ b/src/htx.c @@ -831,8 +831,7 @@ size_t htx_xfer(struct htx *dst, struct htx *src, size_t count, unsigned int fla /* Remove partial headers/trailers from and rollback on to not remove them later */ while (type == HTX_BLK_REQ_SL || type == HTX_BLK_RES_SL || type == HTX_BLK_HDR || type == HTX_BLK_TLR) { - BUG_ON(type != htx_get_blk_type(blk)); - ret -= meta_sz + htx_get_blksz(blk); + ret -= meta_sz + htx_get_blksz(dstblk); htx_remove_blk(dst, dstblk); dstblk = htx_get_tail_blk(dst); blk = htx_get_prev_blk(src, blk);