[PATCH xserver] glamor: Use DestroyPixmap instead of FreePicture for glyph atlas pixmap

Michel Dänzer michel at daenzer.net
Wed Jun 15 02:33:15 UTC 2016


On 15.06.2016 09:10, Keith Packard wrote:
> Nice of FreePicture to take a void * instead of a PicturPtr so that
> this error wasn't caught by the compiler.
> 
> Noticed when resetting the X server left a dangling pixmap around.
> 
> Signed-off-by: Keith Packard <keithp at keithp.com>
> ---
>  glamor/glamor_composite_glyphs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/glamor/glamor_composite_glyphs.c b/glamor/glamor_composite_glyphs.c
> index 50fd026..cc0aa6f 100644
> --- a/glamor/glamor_composite_glyphs.c
> +++ b/glamor/glamor_composite_glyphs.c
> @@ -557,7 +557,7 @@ glamor_free_glyph_atlas(struct glamor_glyph_atlas *atlas)
>      if (!atlas)
>          return;
>      if (atlas->atlas)
> -        FreePicture(atlas->atlas, 0);
> +        (*atlas->atlas->drawable.pScreen->DestroyPixmap)(atlas->atlas);
>      free (atlas);
>  }
>  
> 

Reviewed-by: Michel Dänzer <michel.daenzer at amd.com>


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the xorg-devel mailing list