mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Fix truncation size deserialization [skip ci]
This commit is contained in:
parent
886c8e8348
commit
33e5dedd74
@ -49,7 +49,7 @@ private final class MediaBoxFileMap {
|
||||
return nil
|
||||
}
|
||||
|
||||
var truncationSizeValue: Int32 = 0
|
||||
var truncationSizeValue: Int64 = 0
|
||||
|
||||
var data = Data(count: Int(8 + count * 2 * 8))
|
||||
let dataCount = data.count
|
||||
@ -89,8 +89,10 @@ private final class MediaBoxFileMap {
|
||||
self.ranges = ranges
|
||||
if truncationSizeValue == -1 {
|
||||
self.truncationSize = nil
|
||||
} else if truncationSizeValue < 0 {
|
||||
self.truncationSize = nil
|
||||
} else {
|
||||
self.truncationSize = Int64(truncationSizeValue)
|
||||
self.truncationSize = truncationSizeValue
|
||||
}
|
||||
} else {
|
||||
let crc: UInt32 = firstUInt32
|
||||
|
Loading…
x
Reference in New Issue
Block a user