Mercurial > mplayer.hg
changeset 22130:bca522054afe
Sanity check for vo window dimensions, helps avoid division by zero
with -wid.
author | reimar |
---|---|
date | Mon, 05 Feb 2007 17:47:43 +0000 |
parents | 32a28daf0cf4 |
children | 934010b90043 |
files | libvo/vo_xv.c |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/libvo/vo_xv.c Mon Feb 05 17:15:44 2007 +0000 +++ b/libvo/vo_xv.c Mon Feb 05 17:47:43 2007 +0000 @@ -313,6 +313,8 @@ XGetGeometry(mDisplay, vo_window, &mRoot, &drwX, &drwY, &vo_dwidth, &vo_dheight, &drwBorderWidth, &drwDepth); + if (vo_dwidth <= 0) vo_dwidth = d_width; + if (vo_dheight <= 0) vo_dheight = d_height; drwX = drwY = 0; // coordinates need to be local to the window aspect_save_prescale(vo_dwidth, vo_dheight); } else