mirror of https://github.com/mpv-player/mpv
fixes a segfault which was introduced in this file by the new ratecontrol code
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7137 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
a7d15a362b
commit
8ddf569e86
|
@ -338,6 +338,9 @@ jpeg_enc_t *jpeg_enc_init(int w, int h, int y_psize, int y_rsize,
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/* alloc bogus avctx to keep MPV_common_init from segfaulting */
|
||||
j->s->avctx = calloc(sizeof(*j->s->avctx), 1);
|
||||
|
||||
if (MPV_common_init(j->s) < 0) {
|
||||
free(j->s);
|
||||
free(j);
|
||||
|
|
Loading…
Reference in New Issue