mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-14 05:07:10 +02:00
Fix deadlock in audio for notification repacking.
This commit is contained in:
parent
f1019c8ca4
commit
3cebd6d923
1 changed files with 3 additions and 1 deletions
|
@ -21,7 +21,9 @@ struct ReadBytesWrap {
|
|||
const auto toRead = std::min(
|
||||
int64(buf_size),
|
||||
wrap->size - wrap->offset);
|
||||
if (toRead > 0) {
|
||||
if (!toRead) {
|
||||
return AVERROR_EOF;
|
||||
} else if (toRead > 0) {
|
||||
memcpy(buf, wrap->data + wrap->offset, toRead);
|
||||
wrap->offset += toRead;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue