From 8ab19ba9caa838cff8bbb73b49e401a78bdaa780 Mon Sep 17 00:00:00 2001 From: Arnaud Vrac Date: Thu, 26 Jul 2012 01:52:25 +0200 Subject: [PATCH] video-frame: fix invalid plane id on video frame mapping error --- gst-libs/gst/video/video-frame.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/gst-libs/gst/video/video-frame.c b/gst-libs/gst/video/video-frame.c index 5070c6737f..5ddcd781db 100644 --- a/gst-libs/gst/video/video-frame.c +++ b/gst-libs/gst/video/video-frame.c @@ -126,10 +126,8 @@ no_metadata: frame_map_failed: { GST_ERROR ("failed to map video frame plane %d", i); - do { - i--; + while (--i >= 0) gst_video_meta_unmap (meta, i, &frame->map[i]); - } while (i > 0); return FALSE; } map_failed: