cellAdec: fix uninitialized default size of AVPacketHolder (#12077)

This commit is contained in:
Megamouse 2022-05-25 11:40:51 +02:00 committed by GitHub
parent 961d41d0bd
commit 88ee62be26
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 8 deletions

View file

@ -324,8 +324,6 @@ namespace utils
}
// Prepare to read data
AVPacket packet;
av_init_packet(&packet);
av.frame = av_frame_alloc();
if (!av.frame)
{
@ -335,6 +333,9 @@ namespace utils
}
duration_ms = stream->duration / 1000;
AVPacket packet{};
av_init_packet(&packet);
// Iterate through frames
while (thread_ctrl::state() != thread_state::aborting && av_read_frame(av.format, &packet) >= 0)