Merge "Bluetooth OBEX timeout problem."
This commit is contained in:
@ -397,11 +397,13 @@ public final class ServerOperation implements Operation, BaseStream {
|
||||
&& (headerID != ObexHelper.OBEX_OPCODE_GET_FINAL)) {
|
||||
|
||||
if (length > 3) {
|
||||
byte[] temp = new byte[length];
|
||||
byte[] temp = new byte[length - 3];
|
||||
// First three bytes already read, compensating for this
|
||||
bytesReceived = mInput.read(temp);
|
||||
|
||||
while (bytesReceived != length) {
|
||||
bytesReceived += mInput.read(temp, bytesReceived, length - bytesReceived);
|
||||
while (bytesReceived != temp.length) {
|
||||
bytesReceived += mInput.read(temp, bytesReceived,
|
||||
temp.length - bytesReceived);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user