mirror of https://github.com/mpv-player/mpv
vf: fix NULL pointer issue
"mpi" was accessed right after the if block, that checked that mpi is not NULL. Either the check is uneeded, or the access to "mpi" always crashes. Just move the access inside the checked block.
This commit is contained in:
parent
1809cbcc90
commit
c59a80b77c
|
@ -358,8 +358,8 @@ mp_image_t *vf_get_image(vf_instance_t *vf, unsigned int outfmt,
|
|||
mpi->flags |= MP_IMGFLAG_TYPE_DISPLAYED;
|
||||
}
|
||||
mpi->qscale = NULL;
|
||||
mpi->usage_count++;
|
||||
}
|
||||
mpi->usage_count++;
|
||||
return mpi;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue