diff options
Diffstat (limited to 'video')
-rw-r--r-- | video/out/vo_dmabuf_wayland.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/video/out/vo_dmabuf_wayland.c b/video/out/vo_dmabuf_wayland.c index 1536d6a0c9..f57e6f27ba 100644 --- a/video/out/vo_dmabuf_wayland.c +++ b/video/out/vo_dmabuf_wayland.c @@ -219,14 +219,10 @@ static struct buffer *buffer_check(struct vo *vo, struct mp_image *src) struct buffer *buf; wl_list_for_each(buf, &p->buffer_list, link) { if (buf->id == id) { - if (buf->image) { + if (buf->image) mp_image_unrefp(&buf->image); - buf->image = NULL; - goto done; - } else { - buf->image = src; - return buf; - } + buf->image = src; + return buf; } } |