Skip to content

Commit 24f9c28

Browse files
sjuddglide-copybara-robot
authored andcommitted
Update ByteBufferStream read() to return byte values from 0-255 or -1 if EOF reached.
PiperOrigin-RevId: 269596827
1 parent e021f6b commit 24f9c28

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/src/main/java/com/bumptech/glide/util/ByteBufferUtil.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ public int read() {
194194
if (!byteBuffer.hasRemaining()) {
195195
return -1;
196196
}
197-
return byteBuffer.get();
197+
return byteBuffer.get() & 0xFF;
198198
}
199199

200200
@Override

0 commit comments

Comments
 (0)