OpenSearch/modules/transport-netty4
Tim Brooks a3ade99fcf Fix BytesReferenceStreamInput#skip with offset (#25634)
There is a bug when a call to `BytesReferenceStreamInput` skip is made
on a `BytesReference` that has an initial offset. The offset for the
current slice is added to the current index and then subtracted from the
length. This introduces the possibility of a negative number of bytes to
skip. This happens inside a loop, which leads to an infinte loop.

This commit correctly subtracts the current slice index from the
slice.length. Additionally, the `BytesArrayTests` are modified to test
instances that include an offset.
2017-07-11 09:54:29 -05:00
..
licenses Upgrade to Netty 4.1.13.Final 2017-07-06 15:37:00 -04:00
src Fix BytesReferenceStreamInput#skip with offset (#25634) 2017-07-11 09:54:29 -05:00
build.gradle Upgrade to Netty 4.1.13.Final 2017-07-06 15:37:00 -04:00