Skip to content

Commit

Permalink
deps/media-playback: Just null the first frame pointer on decode
Browse files Browse the repository at this point in the history
memset is a little excessive considering we only check the first
pointer.
  • Loading branch information
Lain-B committed May 26, 2023
1 parent 40ce466 commit 192d33c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion deps/media-playback/media-playback/media.c
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ bool mp_media_prepare_frames(mp_media_t *m)
* these pointers to signify they're not valid. (the obsframe
* structure is only used in the media thread, so this isn't a
* threading issue) */
memset(&m->obsframe, 0, sizeof(m->obsframe));
m->obsframe.data[0] = NULL;

if (m->has_video && !mp_decode_frame(&m->v))
return false;
Expand Down

0 comments on commit 192d33c

Please sign in to comment.