Fix two problems in ByteList#startsWith

First problem is that the offset is not taken into account when short-
circuiting on length, which can lead to ArrayIndexOutOfBoundsException.

The second problem was that instead of reading the real sizes, the code
was making copies of both byte arrays involved in a startsWith check,
just to obtain the length.