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:
wm4 2012-11-01 00:58:39 +01:00
parent 1809cbcc90
commit c59a80b77c
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}