mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Implement optional cached resource data streaming
This commit is contained in:
@@ -148,7 +148,7 @@ public final class WriteBuffer: MemoryBuffer {
|
||||
self.offset = 0
|
||||
}
|
||||
|
||||
public func write(_ data: UnsafeRawPointer, offset: Int, length: Int) {
|
||||
public func write(_ data: UnsafeRawPointer, offset: Int = 0, length: Int) {
|
||||
if self.offset + length > self.capacity {
|
||||
self.capacity = self.offset + length + 256
|
||||
if self.length == 0 {
|
||||
|
||||
Reference in New Issue
Block a user