lavd/xcbgrab: fix comparison with screen size.
authorNicolas George <george@nsup.org>
Wed, 6 May 2015 09:53:19 +0000 (11:53 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 6 May 2015 11:33:17 +0000 (13:33 +0200)
Signed-off-by: Nicolas George <george@nsup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavdevice/xcbgrab.c

index 15512cd..166575c 100644 (file)
@@ -533,8 +533,8 @@ static int create_stream(AVFormatContext *s)
     gc  = xcb_get_geometry(c->conn, c->screen->root);
     geo = xcb_get_geometry_reply(c->conn, gc, NULL);
 
-    if (c->x + c->width >= geo->width ||
-        c->y + c->height >= geo->height) {
+    if (c->x + c->width > geo->width ||
+        c->y + c->height > geo->height) {
         av_log(s, AV_LOG_ERROR,
                "Capture area %dx%d at position %d.%d "
                "outside the screen size %dx%d\n",