present/wnmd: Keep pixmap pointer in present_wnmd_clear_window_flip

The comment was incorrect: Any reference held by the window (see
present_wnmd_execute) is in addition to the one in struct present_vblank
(see present_vblank_create). So if we don't drop the latter, the pixmap
will be leaked.

Reviewed-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
Michel Dänzer 2020-06-19 17:02:40 +02:00 committed by Michel Dänzer
parent 7ae221ad57
commit bc9dd1c71c
1 changed files with 0 additions and 2 deletions

View File

@ -122,8 +122,6 @@ present_wnmd_clear_window_flip(WindowPtr window)
xorg_list_for_each_entry_safe(vblank, tmp, &window_priv->idle_queue, event_queue) {
present_pixmap_idle(vblank->pixmap, vblank->window, vblank->serial, vblank->idle_fence);
/* The pixmap will be destroyed by freeing the window resources. */
vblank->pixmap = NULL;
present_vblank_destroy(vblank);
}