]> git.ipfire.org Git - thirdparty/qemu.git/commit
ui/console: fix texture leak when calling surface_gl_create_texture()
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Mon, 14 Feb 2022 20:13:36 +0000 (00:13 +0400)
committerGerd Hoffmann <kraxel@redhat.com>
Fri, 4 Mar 2022 10:28:37 +0000 (11:28 +0100)
commit6cdcf8810744cbc67074468b7f3c2f50f8e3539c
tree80a17bbc67867add520e0bb624d9508c85ee57e6
parenta9fbce5e94d6b68ec8404f8a466fde873ba2bc73
ui/console: fix texture leak when calling surface_gl_create_texture()

Make surface_gl_create_texture() idempotent: if the surface is already
bound to a texture, do not create a new one.

This fixes texture leaks when there are multiple DBus listeners, for
example.

Reported-by: Akihiko Odaki <akihiko.odaki@gmail.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20220214201337.1814787-3-marcandre.lureau@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
ui/console-gl.c