mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-02 00:17:41 +01:00
Fix several bugs in the local backup restore flow.
This commit is contained in:
committed by
Cody Henthorne
parent
089d8a50b2
commit
9941b2d123
@@ -227,10 +227,11 @@ class EncryptedBackupReader private constructor(
|
||||
try {
|
||||
val length = stream.readVarInt32().also { if (it < 0) return null }
|
||||
val frameBytes: ByteArray = stream.readNBytesOrThrow(length)
|
||||
|
||||
return Frame.ADAPTER.decode(frameBytes)
|
||||
} catch (e: EOFException) {
|
||||
return null
|
||||
} catch (e: IOException) {
|
||||
return read()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user