Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
support (seekable) ByteArrayInputStream#to_io.rewind #3337
this is not possible using
1.7.x remains behaving weirdly on
@kares I appreciate the attribution but the code at 6142ea3#diff-b60adbaec9c15033c4eb0231a09d211aR46 worries me. We can't incorporate code from GPL codebases like this, even if they're been massaged into place a little.
I'd suggest you look at the Android implementation of this logic, which is licensed Apache-2.0. We can incorporate them into a separate file with an Apache license header and it should be compatible with all three of our licenses.
Here's the Android 4.3 impl of Channels at equivalent read method: https://android.googlesource.com/platform/libcore/+/android-4.3_r1/luni/src/main/java/java/nio/channels/Channels.java#297
Testing seems fine, I'll push shortly.
Last suggestions, if you get a chance (just throw them on master):