Doug Engert reports that large tokens are corrupted when being sent
using RX. This patch fixes two bugs which prevent the transmission
and receipt of multiple packet exchanges.
(cherry picked from commit
f42701022203605f8509b106fe8ca1677666aaa9)
j = MIN(resid, packet->wirevec[i].iov_len - (offset - l));
memcpy(out, (char *)(packet->wirevec[i].iov_base) + (offset - l), j);
resid -= j;
- l += packet->wirevec[i].iov_len;
+ out += j;
+ l += packet->wirevec[i].iov_len;
i++;
}
j = MIN(resid, packet->wirevec[i].iov_len - (offset - l));
memcpy(b, in, j);
resid -= j;
+ in += j;
l += packet->wirevec[i].iov_len;
i++;
}