Full threaddar8919·The second code snippet looks wrong,write(out, buf, (r - w)) should be write(out, buf + w, r - w)View on HN