1
mirror of https://github.com/mpv-player/mpv synced 2024-07-31 16:29:58 +02:00

report error if bad dimensions requested (<=0)

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@6198 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
alex 2002-05-26 15:55:29 +00:00
parent c79050c108
commit fd0fa7d6d1

View File

@ -18,6 +18,12 @@ static int config(struct vf_instance_s* vf,
int width, int height, int d_width, int d_height,
unsigned int flags, unsigned int outfmt){
if ((width <= 0) || (height <= 0) || (d_width <= 0) || (d_height <= 0))
{
mp_msg(MSGT_CPLAYER, MSGL_ERR, "VO: invalid dimensions!\n");
return 0;
}
if(video_out->get_info)
{ const vo_info_t *info = video_out->get_info();
mp_msg(MSGT_CPLAYER,MSGL_INFO,"VO: [%s] %dx%d => %dx%d %s %s%s%s%s\n",info->short_name,