mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-06-02 11:26:09 +02:00
Fixed a bug where less than the requested length was read before EOF in PineTime DFU
This commit is contained in:
parent
004355f69f
commit
2928a0e13b
|
@ -75,8 +75,9 @@ public class PineTimeInstallHandler implements InstallHandler {
|
|||
|
||||
final byte[] buffer = new byte[1024];
|
||||
|
||||
while (zipInputStream.read(buffer, 0, buffer.length) != -1) {
|
||||
json.append(new String(buffer));
|
||||
int read;
|
||||
while ((read = zipInputStream.read(buffer, 0, buffer.length)) != -1) {
|
||||
json.append(new String(buffer, 0, read));
|
||||
}
|
||||
|
||||
Gson gson = new Gson();
|
||||
|
|
Loading…
Reference in New Issue
Block a user